I have WASM files in two flavors: modules and components. A component, according to my understanding, is a module accompanied by an embedded but explicit interface definition which was provided as WIT (WASM interface types).
Now, I can create both of these flavors but so far I can only optimize modules. For optimization, I take wasm-opt, e.g.
wasm-opt -O3 -o mywasmopt.wasm mywasm.wasm
It works only for modules, not for components. My question is: How do I optimize components the same way I am used to optimize modules?
Last updated: Apr 07 2025 at 12:05 UTC