-
-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Module not found Warning when using ws in a webpack bundle #1126
Comments
I think it is because I "require" the |
This is a recurring issue, we already have a note at the beginning of the README but it seems it is not sufficient. ws does not work in the browser, the native |
Closing, feel free to continue discussing on the closed thread. |
Getting the same issue when using |
any solution on this? |
Hi, I get this issue in the main process of an Electron app. This is a Node process, not a client process. |
@dalen Did you find a solution? I have the exact same case as you. |
@hrmoller yes, I added Works as a workaround for now at least. |
The problem is still there on Electron main thread (== node code, not browser). // in webpack.config.js
externals: {
bufferutil: "bufferutil",
"utf-8-validate": "utf-8-validate",
} |
This workaround using https://medium.com/code-oil/webpack-javascript-bundling-for-both-front-end-and-back-end-b95f1b429810 |
|
Actually works thanks |
Just some notes for anyone that might land here in the future:
Note for
|
Do I have to install
bufferutil
andutf-8-validate
module to remove the warning? Why are these two modules separated from the main module? How do I know when I need to use them? I haven't written anything related to these two modules. I think maybews
uses these two modules.The text was updated successfully, but these errors were encountered: