Skip to content
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

Switch from CommonJS to ESM modules #890

Open
Balearica opened this issue Feb 14, 2024 · 3 comments
Open

Switch from CommonJS to ESM modules #890

Balearica opened this issue Feb 14, 2024 · 3 comments
Labels
breaking change Fix would require new major version.

Comments

@Balearica
Copy link
Member

This would be one way of fixing #876, and should probably happen eventually regardless.

@Balearica Balearica added this to the v6.0 milestone Feb 14, 2024
@laurent22
Copy link

Please don't switch to ESM or keep the CommonJS release too. Many projects cannot easily switch to ESM and TesseractJS is unique enough that it won't be possible to find an alternative for non-ESM projects.

@Balearica Balearica removed this from the v6.0 milestone Jun 20, 2024
@Balearica
Copy link
Member Author

I've removed the v6 milestone. My understanding is that the Node.js ecosystem will transition to ESM eventually, however I don't think we need to be on the bleeding edge of this, and most Node.js projects are still using CJS. Looking at node-fetch (the reason this came up), just 5 million of the 43 million weekly downloads (12%) are from the ESM versions.

@Balearica Balearica added the breaking change Fix would require new major version. label Jun 20, 2024
@laurent22
Copy link

Thank you for taking the time to investigate this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking change Fix would require new major version.
Projects
None yet
Development

No branches or pull requests

2 participants