libavoid-js
    Preparing search index...

    Interface AvoidLibType

    interface AvoidLibType {
        avoidLib: Avoid | undefined;
        load(wasm?: string | URL | Module): Promise<void>;
        getInstance(): Avoid;
    }
    Index
    • Loads and initialises the wasm module. Call once before getInstance().

      Parameters

      • Optionalwasm: string | URL | Module

        libavoid.wasm as a path or URL to fetch, or as an already compiled WebAssembly.Module to only instantiate. Omit it if the file is served next to the JS bundle or your bundler emits it. A module must be the libavoid-js/libavoid.wasm of the same libavoid-js version.

      Returns Promise<void>

      TypeError if wasm is none of these.

    avoidLib: Avoid | undefined

    The module once load() has completed, otherwise undefined.