Skip to content

chore: use node: imports and fs-extra/esm import#539

Merged
ghiscoding merged 1 commit intonextfrom
chore/use-node-protocol-imports
Apr 4, 2023
Merged

chore: use node: imports and fs-extra/esm import#539
ghiscoding merged 1 commit intonextfrom
chore/use-node-protocol-imports

Conversation

@ghiscoding
Copy link
Copy Markdown
Member

@ghiscoding ghiscoding commented Apr 4, 2023

Description

NodeJS is now telling us to prefer import: instead of default imports for better ESM support, for example from 'fs' should be from 'node:fs'. We also use fs-extra which is giving us hint to use fs-extra/esm for better ESM support.

Motivation and Context

Prefer ESM approach as much as possible for the next major release, this is also part of a breaking change since it requires Node 16 and higher

How Has This Been Tested?

Types of changes

  • Chore (change that has absolutely no effect on users)
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

@codecov
Copy link
Copy Markdown

codecov bot commented Apr 4, 2023

Codecov Report

❗ No coverage uploaded for pull request base (next@41217cc). Click here to learn what that means.
The diff coverage is n/a.

@@           Coverage Diff           @@
##             next     #539   +/-   ##
=======================================
  Coverage        ?   97.55%           
=======================================
  Files           ?      160           
  Lines           ?    12768           
  Branches        ?     2054           
=======================================
  Hits            ?    12454           
  Misses          ?      313           
  Partials        ?        1           

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@ghiscoding ghiscoding merged commit ac85e16 into next Apr 4, 2023
@ghiscoding ghiscoding deleted the chore/use-node-protocol-imports branch April 4, 2023 13:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant