-
Notifications
You must be signed in to change notification settings - Fork 207
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
improve ESM compatibility #1383
Comments
the easiest thing to do by far is to write modern javascript today - not an esm wrapper, but real esm output, which will also dramatically drop the size of your bundle - then use a tool like rollup or webpack to produce your old-world cjs module |
- Use thin ESM wrapper for CJS output instead of double tsc compilation. - Replace webpack with esbuild - Add bundled versions of ESM build. fixes #1383
- Use thin ESM wrapper for CJS output instead of double tsc compilation. - Replace webpack with esbuild - Add bundled versions of ESM build. fixes #1383
- Use thin ESM wrapper for CJS output instead of double tsc compilation. - Replace webpack with esbuild - Add bundled versions of ESM build. fixes #1383
- Use thin ESM wrapper for CJS output instead of double tsc compilation. - Replace webpack with esbuild - Add bundled versions of ESM build. fixes #1383
- Use thin ESM wrapper for CJS output instead of double tsc compilation. - Replace webpack with esbuild - Add bundled versions of ESM build. fixes #1383
- Use thin ESM wrapper for CJS output instead of double tsc compilation. - Replace webpack with esbuild - Add bundled versions of ESM build. fixes #1383
- Use thin ESM wrapper for CJS output instead of double tsc compilation. - Replace webpack with esbuild - Add bundled versions of ESM build. fixes #1383
- Use thin ESM wrapper for CJS output instead of double tsc compilation. - Replace webpack with esbuild - Add bundled versions of ESM build. fixes #1383
- Use thin ESM wrapper for CJS output instead of double tsc compilation. - Replace webpack with esbuild - Add bundled versions of ESM build. fixes #1383
- Use thin ESM wrapper for CJS output instead of double tsc compilation. - Replace webpack with esbuild - Add bundled versions of ESM build. fixes #1383
- Use thin ESM wrapper for CJS output instead of double tsc compilation. - Replace webpack with esbuild - Add bundled versions of ESM build. fixes #1383
I prefer to avoid multiple (unbundled) versions of the code inside the npm package. Seems like I've managed to get it working in the upcoming PR. |
- Use thin ESM wrapper for CJS output instead of double tsc compilation. - Replace webpack with esbuild - Add bundled versions of ESM build. fixes #1383
- Use thin ESM wrapper for CJS output instead of double tsc compilation. - Replace webpack with esbuild - Add bundled versions of ESM build. fixes #1383
- Use thin ESM wrapper for CJS output instead of double tsc compilation. - Replace webpack with esbuild - Add bundled versions of ESM build. fixes #1383
- Use thin ESM wrapper for CJS output instead of double tsc compilation. - Replace webpack with esbuild - Add bundled versions of ESM build. fixes #1383
Update (released in version 8.0)
https://unpkg.com/chevrotain/lib_esm/chevrotain.mjs
https://unpkg.com/chevrotain/lib_esm/chevrotain.min.mjs
This is a follow up to issues:
Current status
lib_esm
folder)Preferred Approach
A thin ESM wrapper with one a single TSC compilation output.
Current issues
I've had issues with implementing a thin ESM wrapper myself, possibly due to to how Typescript implements "exporting".
References
The text was updated successfully, but these errors were encountered: