I have an electron app that should do with the TCP server and on my client side I had this error”_a.Socket is not a constructor”, after connecting to my server, the server worked normally, but the connection had issues, connection code below
var client = new net.Socket();
client.connect(3000, '127.0.0.1', function() {
console.log('Connected');
client.write('Hello, server! Love, Client.');
});
New contributor
Mohamed Lemine El Hadj is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
1