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

Webpack 5 - AntlrTS in Browser #546

Open
NicoLaval opened this issue Sep 12, 2023 · 3 comments
Open

Webpack 5 - AntlrTS in Browser #546

NicoLaval opened this issue Sep 12, 2023 · 3 comments

Comments

@NicoLaval
Copy link

Since webpack release to v5, some required lib for browser running are missing:

BREAKING CHANGE: webpack < 5 used to include polyfills for node.js core modules by default.
This is no longer the case. Verify if you need this module and configure a polyfill for it.

If you want to include a polyfill, you need to:
        - add a fallback 'resolve.fallback: { "util": require.resolve("util/") }'
        - install 'util'
If you don't want to include a polyfill, you can use an empty module like this:
        resolve.fallback: { "util": false }

Is it possible to add util, assert and process to the antlr4ts bundle?

@voronovmaksim
Copy link

voronovmaksim commented Sep 26, 2023

I faced with the same issue.
Is there WA?

@NicoLaval
Copy link
Author

At this point, I added react-app-rewired to my React app to override Webpack config adding these packages, but I don't find it very nice.

@1R053
Copy link

1R053 commented May 17, 2024

see #549 - not sure though if this is caused be the antlr runtime itself

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