@pumpkin-plugins/signing API / wasm / parseSections
Function: parseSections()
parseSections(
wasm):WasmSection[]
Defined in: wasm.ts:73
Splits a wasm binary into its sections. Core modules and components share the framing (an 8-byte header, then sections), and the version bytes aren't checked, so both work.
Parameters
wasm
Uint8Array
The binary.
Returns
Every section in file order; custom sections carry their name and data.
Throws
When the bytes aren't a well-formed wasm binary.