-
-
Notifications
You must be signed in to change notification settings - Fork 693
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
please provide commonjs exports again #1597
Comments
You can continue to use v4, which will continue to be commonjs, and maintenance will continue while a significant user base remains on v4. If you want to migrate to ESM, then v5 is ready for you when you do. I’m closing this issue as we’re confident in the choice we have made, and so there’s nothing to action here. Despite the issue being closed, I encourage further discussion here. If you have any concerns please continue, but I want to reaffirm: v5 will continue to be ESM only, and v4 will continue to be supported while it still sees heavy use. |
Have you explicitly encouraged plugin authors ( |
The core team has limited bandwidth, and ultimately it is up to plugin authors to distribute and maintain their code as they see fit. |
This may or may not be related to this. Upgrading from v4 to v5, when running tests using
Solution: downgrade to |
@bamse16 it will be the same if you use basically |
Mocha's support for TypeScript with ESM is still experimental (still!!): mochajs/mocha-examples#47
ESM loaders are only at release candidate status in the current Node LTS (20): https://nodejs.org/dist/latest-v20.x/docs/api/module.html#customization-hooks
Furthermore it doesn't seem like a majority of npm packages are likely to become pure ESM anytime soon: https://lannonbr.com/blog/esm-checker-postmortem/
I think that's a sufficient example why it's just too soon for the entire ecosystem to move to pure ESM. Many projects will be unable to migrate to a pure-ESM version of Chai for a long time. I may be the first person to complain about this but I know others are soon to follow.
The text was updated successfully, but these errors were encountered: