I am trying to import the javascript implementation of stockfish into my react app. I can replicate the above error by adding the following:
let stockfish = new Worker('stockfish.js');
I have already tried to clear my cache and I think that it has to do with how I am loading stockfish.js. To replicate the error, all you have to do is create a new react app using create-react-app, install stockfish and add the above line.
This has been asked before (for example) but I can't find anything that applies to my situation.