Chrome Extension Socket io node js
问题 I need to create a chrome extension which shows a notification when we get a message from socket io node js server. How to include socket io in chrome extension? I am not able to get this to working. Content.js:- Uncaught ReferenceError: io is not defined var socket = io.connect('http://localhost:1337'); socket.on("hello",function(data){ console.log(data.text); chrome.runtime.sendMessage({msg:"socket",text:data.text},function(response){}); }); Manifest:- This is not importing socket io Failed