mirror of
https://github.com/denoland/deno.git
synced 2024-11-24 15:19:26 -05:00
b6cdb31c05
PrismJS uses `WorkerGlobalScope` and `self` for detecting browser's Web
Worker context:
59e5a34713/prism.js (L11)
Now the detection logic above is broken when it's imported from Deno's
Web Worker context because we only hide `self` (Prism assumes when
`WorkerGlobalScope` is available, `self` is also available).
This change fixes the above by also hiding `WorkerGlobalScope` global in
Node compat mode.
closes #25008
12 lines
308 B
TypeScript
12 lines
308 B
TypeScript
new Worker(new URL("./worker1.ts", import.meta.url), {
|
|
type: "module",
|
|
});
|
|
new Worker(new URL("./worker2.ts", import.meta.url), {
|
|
type: "module",
|
|
});
|
|
new Worker(new URL("./worker3.ts", import.meta.url), {
|
|
type: "module",
|
|
});
|
|
new Worker(new URL("./worker4.ts", import.meta.url), {
|
|
type: "module",
|
|
});
|