MDN wants to talk to developers like you: https://qsurvey.mozilla.com/s3/8d22564490d8

WebAssembly.Memory.prototype

This is an experimental technology
Because this technology's specification has not stabilized, check the compatibility table for usage in various browsers. Also note that the syntax and behavior of an experimental technology is subject to change in future versions of browsers as the specification changes.

The WebAssembly.Memory.prototype property represents the prototype for the WebAssembly.Memory() constructor.

Property attributes of WebAssembly.Memory.prototype
Writable no
Enumerable no
Configurable no

Description

All WebAssembly.Memory instances inherit from Memory.prototype. The prototype object of the WebAssembly.Memory() constructor can be modified to affect all WebAssembly.Memory instances.

Properties

Memory.prototype.constructor
Returns the function that created this object's instance. By default this is the WebAssembly.Memory() constructor.
Memory.prototype.buffer
An accessor property that returns the buffer contained in the memory.

Methods

Memory.prototype.grow()
Increases the size of the memory instance by a specified number of WebAssembly pages (each one is 64KB in size).

Specifications

Specification Status Comment
Web Assembly JavaScript API
The definition of 'Memory' in that specification.
Draft Initial draft definition.

Browser compatibility

Feature Chrome Edge Firefox (Gecko) Internet Explorer Opera Safari (WebKit)
Basic support 57 No support 52 (52) No support (Yes) No support
Feature Chrome for Android Android Webview Edge Mobile Firefox Mobile (Gecko) IE Mobile Opera Mobile Safari Mobile
Basic support 57 57 No support 52.0 (52) No support No support No support

See also

Document Tags and Contributors

 Contributors to this page: fscholz, chrisdavidmills
 Last updated by: fscholz,