Does not work in web worker #5
Carregando…
x
Criar uma nova questão referindo esta
Bloquear um utilizador
Nenhuma descrição fornecida.
Eliminar o ramo "%!s()"
Eliminar um ramo é algo permanente. Embora o ramo eliminado possa continuar a existir por um breve período de tempo antes de ser realmente removido, a operação NÃO PODERÁ ser desfeita na maioria dos casos. Quer continuar?
error message:
Can you propose a solution?
Is
atob
defined on...self
or whatever it is that workers have?Does
globalThis
work?just with the function name works for me (both browser and web work)
reference:
https://caniuse.com/#search=atob
https://github.com/hughsk/atob-lite/blob/master/atob-browser.js
How about just put
var window = self;
in your WebWorker script?So many things depend on this and it is so abused by things like webpack and browserify, etc, etc that I don't want to rock the boat.
I could release a version 3 that uses something like:
That seems make sense. Thanks!