corevm-codec
    Preparing search index...

    Function initWithExports

    • Initialize the library using WebAssembly instance exports.

      Use this function to asynchronously initialize the library. This function is a simple setter that doesn't involve WebAssembly compilation.

      import { IMPORT_OBJECT, initWithExports } from 'corevm-codec/loader'
      import codeURL from 'corevm-codec/code.wasm?url' // Vite.

      const result = await WebAssembly.instantiateStreaming(fetch(codeURL), IMPORT_OBJECT)
      initWithExports(result.instance.exports)

      Parameters

      • exports: any

      Returns void