Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/deno/cli/tsc/dts/lib.deno.shared_globals.d.ts>WebAssembly.Table

A modern runtime for JavaScript and TypeScript.
Go to Latest
class WebAssembly.Table
import { WebAssembly } from "https://deno.land/x/deno@v1.40.5/cli/tsc/dts/lib.deno.shared_globals.d.ts";
const { Table } = WebAssembly;

The WebAssembly.Table() object is a JavaScript wrapper object — an array-like structure representing a WebAssembly Table, which stores function references. A table created by JavaScript or in WebAssembly code will be accessible and mutable from both JavaScript and WebAssembly.

MDN

Constructors

new
Table(descriptor: TableDescriptor)

Creates a new Table object.

Properties

readonly
length: number

Returns the length of the table, i.e. the number of elements.

Methods

get(index: number): Function | null

Accessor function — gets the element stored at a given index.

grow(delta: number): number

Increases the size of the Table instance by a specified number of elements.

set(index: number, value: Function | null): void

Sets an element stored at a given index to a given value.