-
-
Notifications
You must be signed in to change notification settings - Fork 40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Usage of ESM imports instead of CommonJS #251
Comments
I'm not so sure on this one. I would maybe push this one major version forward. |
Could you elaborate a little bit more? |
The downsides is that we, in addition to other changes, need to change how we import this module in all the projects that uses this module + ideally also convert those to ESM then. As ESM can easily import CommonJS in Node I think it would be better to start converting the individual users to ESM before converting this module. Also: I would ideally have the ESM change in a version where there are no other breaking changes as it's enough of a breaking change to migrate to, also having to deal with other breaking changes at the same time becomes a bit too much, so I would rather avoid it if possible :) |
Sounds good to me! 👍 |
pkg-conf was also converted to ESM recently - it's much smaller in size now |
@jimmywarting We can use many ESM modules in CJS by importing them like |
oh great, not many package have the luxury of using lazy import |
Currently, there are #238, #247 and #262 PRs to fix, if it is possible. |
all doe i would have prefer if it got switched to ESM-only, but understand if you are not ready yet to go full ESM-only if you missed it node-fetch@3 (the largest http lib) just went ESM-only :P |
I agree I would love to switch to ESM-only, but there are so many things breaking with this change that we still need to wait a little bit before doing that. |
for some i think the transition could be easy as many are just executed from cli like so: |
@divlo Okay with you if we close this as completed? |
@voxpelli Why? This is not completed? |
@divlo Remembered wrongly that we had already done the move here, that this was only open due to Then let’s get the ESM:ing started rather than waiting for |
Unlikely to be done. |
We should use ESM imports instead of CommonJS.
See: https://gist.github.com/sindresorhus/a39789f98801d908bbc7ff3ecc99d99c
We'll be able to merge #238, #247, and #262 (dependencies updates that only work with ESM) after this change.
Note: It is a BREAKING CHANGE as
standard-engine
will only work with ESM.To offer a smoother transition for packages that depends on
standard-engine
, we should first migrate them to ESM.Status
The text was updated successfully, but these errors were encountered: