Answer the question
In order to leave comments, you need to log in
How to fix error when using socket io in Chrome Extension?
I want to use socket.io in my extension, but when I import the library, the extension throws an "Uncaught ReferenceError: document is not defined" error. I found out that socket.io does check document and window, but in background.js I can't use n. document API, nor window object. I am using manifest v3. What do I need to do to use socket.io?
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