Closed zorahrel closed 7 years ago
I haven't tested with Webpack 3 yet, will look into it. fs
and net
look like Node.js built in modules, are you importing them in your client codes? Are you able to provide some more info? Project structure, webpack config file, etc if possible. Thanks!
Looks like sockjs-client
will require
module debug
if it not PROD env which tries to detect and ends up importing the file for Node.js
instead of browser. Can you try to specify honorPackage
option to look for browser first?
new DirectoryNamedWebpackPlugin({
honorPackage: ["browser", "main"],
// any other options needed
})
Please let me know if this works.
Can you please let me know if this plugin works for you now? Thanks!
I am closing this now as I have upgraded WP to version 3 for our project and the plugin works fine. Can't do much without further info.
Hi @shaketbaby, I was having the same problem here.
The honorPackage
has resolved the issue.
I updated to Webpack 3, if I add the plugin in resolve's plugins list I have this error in console.