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

the package is not compatible with ES6 #53

Closed
its-dibo opened this issue Jan 14, 2022 · 3 comments
Closed

the package is not compatible with ES6 #53

its-dibo opened this issue Jan 14, 2022 · 3 comments

Comments

@its-dibo
Copy link

its-dibo commented Jan 14, 2022

require() of ES Module node_modules/strip-json-comments/index.js not supported.
Instead change the require of index.js to a dynamic import() which is available in all CommonJS modules

minimal repo

version: 4.0.0
tested on node v14 & v16 LTS

@sindresorhus
Copy link
Owner

@its-dibo
Copy link
Author

its-dibo commented Jan 15, 2022

I updated the issue details with a minimal repo that follows the typical steps in your link

run npm start or npm run start:loader in the terminal

@mrchantey
Copy link

Looks like the devs have decided to lock in ES6 only. For those looking for a similar utility package that still supports require, check out jsonminify.

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

No branches or pull requests

3 participants