using new URL('worker.js', import.meta.url) works in prod but not dev
using import workerUri from 'worker?url work in dev but not prod
using new URL('thing.wasm', import.meta.url) to import wasm from inside a worker does not work in dev or prod, we must instead pass the wasm uri down from the calling application where it is imported via import wasmUri from 'wasm?url'
Vite has some inconsistencies when dealing with importing workers in prod vs dev mode.
Then more problems if those workers attempt to import wasm.
https://github.com/vitejs/vite/issues/13314
new URL('worker.js', import.meta.url)
works in prod but not devimport workerUri from 'worker?url
work in dev but not prodnew URL('thing.wasm', import.meta.url)
to import wasm from inside a worker does not work in dev or prod, we must instead pass the wasm uri down from the calling application where it is imported viaimport wasmUri from 'wasm?url'