easternbloc / node-stomp-client

A STOMP client for Node.js
Other
93 stars 47 forks source link

Can't resolve 'tls' ,how to resolve it? #67

Open codepandy opened 7 years ago

codepandy commented 7 years ago

ERROR in ./node_modules/stomp-client/lib/client.js Module not found: Error: Can't resolve 'tls' in 'C:\projects\demos\STOMP\node_modules\stomp-client\l ib' @ ./node_modules/stomp-client/lib/client.js 3:10-24 @ ./src/requireComponent.js @ ./src/index.js @ multi (webpack)-dev-server/client?http://localhost:8686 ./src/index.js

easternbloc commented 6 years ago

what were your steps to get to this?

benhorst commented 6 years ago

Can't speak for codepandy directly, but it happens when you try to build a webpack bundle for a browser target. I tried it too before I realized that the client is built for nodejs, not the browser platform (inclusion of "client" threw me in the name).