Open dotellie opened 7 months ago
It's unfortunately not feasible/easy for dnt to analyze this and realize that it needs to include the Wasm file:
We're working on adding Wasm imports to Deno and that would make the .wasm
file part of the module graph, in which case dnt would be able to easily include it.
For now, I'd recommend that workaround, but also check the status code to ensure it fails when it can't reach the server:
// ex. something like
if (!res.ok) {
console.error(await res.text());
throw new Error(`Failed downloading: ${res.statusText}`);
}
Ah yep that makes a lot of sense. And good call on the error checking - I think I was in ugly code mode yesterday 😂 Thank you for the quick response!
I'm using a Deno module that has some WASM code included (https://github.com/unyt-org/typescript-transpiler) and after running dnt,
transpiler_bg.wasm
is missing in thedeps
folder.Working around this issue with
works just fine, so I'm assuming that this could be a bug in dnt 😅