WebAssembly Support

Detect native WebAssembly support.

Usage

var hasWebAssemblySupport = require( '@stdlib/utils/detect-wasm-support' );

hasWebAssemblySupport()

Detects if a runtime environment supports WebAssembly.

var bool = hasWebAssemblySupport();
// returns <boolean>

Examples

var hasWebAssemblySupport = require( '@stdlib/utils/detect-wasm-support' );

var bool = hasWebAssemblySupport();
if ( bool ) {
    console.log( 'Environment has WebAssembly support.' );
} else {
    console.log( 'Environment lacks WebAssembly support.' );
}

CLI

Usage

Usage: haswasm [options]

Options:

  -h,    --help                Print this message.
  -V,    --version             Print the package version.

Examples

$ haswasm
<boolean>