im trying to spawn a web worker inside a web worker but im getting this error:
mainWorker.js:92 Uncaught ReferenceError: Worker is not defined
using this code:
var worker = new Worker('subWorker.js');
worker.postMessage(......);
is this possible in some way??
For anyone who stumbles here, nested workers now have some support in Chrome at least: https://www.chromestatus.com/feature/6080438103703552:
Dedicated workers can create nested workers, but shared workers and service workers cannot.
Creating a nested dedicated worker from a shared worker is not yet supported.
Nested shared workers are also in the spec, but there is no plan to support them at this time.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With