Closed
Description
A while ago, I had realized that there is an error when trying to use socket.io-client
within a WebPack module. It turns out, that "dist/debug.js" can not be located. I did a little bit of unixy research:
Ingwie@Ingwies-Macbook-Pro.local ~/W/BIRD3 $ grep -r "dist/debug" node_modules/socket.io-client/
node_modules/socket.io-client//node_modules/engine.io-client/node_modules/debug/Makefile:all: dist/debug.js
node_modules/socket.io-client//node_modules/engine.io-client/node_modules/debug/Makefile:dist/debug.js: node_modules browser.js debug.js dist
Ingwie@Ingwies-Macbook-Pro.local ~/W/BIRD3 $ find node_modules/socket.io-client -name "dist"
[empty]
Ingwie@Ingwies-Macbook-Pro.local ~/W/BIRD3 $ find node_modules -name "debug.js" | grep dist
Conclusion: The dist
folder must be a virtual folder that is used during the Browserify process... Now, how exactly do I get rid of that? It's really heavy-lifting to require("socket.io-client/socket.io")
although there already IS a system that knows commonJS.
With heavy-lifting, I mean that adding the SIO client is ~350KB... A fix would be pretty awesome.
Metadata
Metadata
Assignees
Labels
No labels