Answer the question
In order to leave comments, you need to log in
Why does socket.io server crash during socket.emit on client side?
My node.js socket server crashes with this error
C:\Users\M4k5y\source\repos\chatik\chatik\node_modules\socket.io\lib\socket.js:514
emit.apply(self, event); TypeError: CreateListFromArrayLike called on non-object
at C:\Users\M4k5y\source\repos\chatik\chatik\node_modules\socket.io\lib\socket.js:514:12
at _combinedTickCallback (internal/process/next_tick.js: 73:7)
at process._tickCallback (internal/process/next_tick.js:104:9)
Here is the js code from the browser
var socket = io('http://localhost:80');
socket.emit('lol', "hello");
var io1 = require('socket.io')(80);
io1.on('lol', function (data) { console.log(data) });
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question