DEV Community

Discussion on: Learn WebSockets By Building Simple Chat App

Collapse
 
maccauhuru profile image
Simba Mupfukudzwa

Great post and thank you for sharing.
2 issues i faced but was able to rectify incase someone else is having issues.

The very first line needs to be changed in order to initialize npm

change : npm i -Y && npm i ws && touch server.js

to : npm init -Y && npm i ws && touch server.js

On the server.js file make the sure everywhere you have the word 'webWorker' is converted to 'WebWorker' with UpperCases to make it work and avoid a reference error.

Other than those two little things, app works great and is easy to follow.