WebAssembly.Tag() constructor

The WebAssembly.Tag() constructor creates a new WebAssembly.Tag object instance.

Syntax

js
new WebAssembly.Tag(type)

Parameters

type

An object that can contain the following members:

parameters

An array of strings representing the exception type's parameters and their types. The strings can be any Wasm type.

Exceptions

TypeError

Thrown if at least one of these conditions is true:

Examples

undefined

Basic usage

This creates a tag with two values.

js
const tag = new WebAssembly.Tag({ parameters: ["i32", "i64"] });

Specifications

See also