There is a bit of a concern from a perf/responsiveness standpoint with having this being a C# source generator, in that the generator needs to parse the .wasm file to create the shim types. Typically, AdditionalFile values are meant to be textural so the infrastructure can provide the file content relatively quickly. (At least I think that's the concern). Anyway, I'm thinking of providing a .NET tool that will let someone create the shim classes from the command line.
This means I'll need to do some project restructuring:
Create a "Core" project that (mostly) does what WasmTypeBuilder does now (and create a related test project)
Use "Core" from WebAssembly.Generator to create the gen'd text.
Create a "Tool" project that provides the gen functionality from the command line.
There is a bit of a concern from a perf/responsiveness standpoint with having this being a C# source generator, in that the generator needs to parse the .wasm file to create the shim types. Typically,
AdditionalFile
values are meant to be textural so the infrastructure can provide the file content relatively quickly. (At least I think that's the concern). Anyway, I'm thinking of providing a .NET tool that will let someone create the shim classes from the command line.This means I'll need to do some project restructuring:
WasmTypeBuilder
does now (and create a related test project)WebAssembly.Generator
to create the gen'd text.