René's URL Explorer Experiment


Title: Using the WebAssembly JavaScript API - WebAssembly | MDN

Open Graph Title: Using the WebAssembly JavaScript API - WebAssembly | MDN

Description: This article teaches you how to use the key features of the WebAssembly JavaScript API, including loading Wasm modules and manipulating WebAssembly memories, tables, and globals.

Open Graph Description: This article teaches you how to use the key features of the WebAssembly JavaScript API, including loading Wasm modules and manipulating WebAssembly memories, tables, and globals.

Opengraph URL: https://developer.mozilla.org/en-US/docs/WebAssembly/Guides/Using_the_JavaScript_API

direct link

Domain: developer.mozilla.org

IPv4 address: 151.101.65.91

og:localeen_US
og:imagehttps://developer.mozilla.org/mdn-social-image.46ac2375.png
og:image:typeimage/png
og:image:height1024
og:image:width1024
og:image:altThe MDN logo
og:site_nameMDN Web Docs
twitter:cardsummary
twitter:creatorMozDevNet
position3

Links:

Skip to main contenthttps://developer.mozilla.org/en-US/docs/WebAssembly/Using_the_JavaScript_API#content
Skip to searchhttps://developer.mozilla.org/en-US/docs/WebAssembly/Using_the_JavaScript_API#mdn-search
MDN https://developer.mozilla.org/en-US/
HTML: Markup languagehttps://developer.mozilla.org/en-US/docs/Web/HTML
Elementshttps://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Elements
Global attributeshttps://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Global_attributes
Attributeshttps://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Attributes
See all…https://developer.mozilla.org/en-US/docs/Web/HTML/Reference
Responsive imageshttps://developer.mozilla.org/en-US/docs/Web/HTML/Guides/Responsive_images
HTML cheatsheethttps://developer.mozilla.org/en-US/docs/Web/HTML/Guides/Cheatsheet
Date & time formatshttps://developer.mozilla.org/en-US/docs/Web/HTML/Guides/Date_and_time_formats
See all…https://developer.mozilla.org/en-US/docs/Web/HTML/Guides
SVGhttps://developer.mozilla.org/en-US/docs/Web/SVG
MathMLhttps://developer.mozilla.org/en-US/docs/Web/MathML
XMLhttps://developer.mozilla.org/en-US/docs/Web/XML
CSS: Styling languagehttps://developer.mozilla.org/en-US/docs/Web/CSS
Propertieshttps://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Properties
Selectorshttps://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Selectors
At-ruleshttps://developer.mozilla.org/en-US/docs/Web/CSS/Reference/At-rules
Valueshttps://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Values
See all…https://developer.mozilla.org/en-US/docs/Web/CSS/Reference
Box modelhttps://developer.mozilla.org/en-US/docs/Web/CSS/Guides/Box_model/Introduction
Animationshttps://developer.mozilla.org/en-US/docs/Web/CSS/Guides/Animations/Using
Flexboxhttps://developer.mozilla.org/en-US/docs/Web/CSS/Guides/Flexible_box_layout/Basic_concepts
Colorshttps://developer.mozilla.org/en-US/docs/Web/CSS/Guides/Colors/Applying_color
See all…https://developer.mozilla.org/en-US/docs/Web/CSS/Guides
Column layoutshttps://developer.mozilla.org/en-US/docs/Web/CSS/How_to/Layout_cookbook/Column_layouts
Centering an elementhttps://developer.mozilla.org/en-US/docs/Web/CSS/How_to/Layout_cookbook/Center_an_element
Card componenthttps://developer.mozilla.org/en-US/docs/Web/CSS/How_to/Layout_cookbook/Card
See all…https://developer.mozilla.org/en-US/docs/Web/CSS/How_to/Layout_cookbook
JavaScript: Scripting languagehttps://developer.mozilla.org/en-US/docs/Web/JavaScript
Standard built-in objectshttps://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects
Expressions & operatorshttps://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators
Statements & declarationshttps://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements
Functionshttps://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions
See all…https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference
Control flow & error handlinghttps://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Control_flow_and_error_handling
Loops and iterationhttps://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Loops_and_iteration
Working with objectshttps://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Working_with_objects
Using classeshttps://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Using_classes
See all…https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide
Web APIs: Programming interfaceshttps://developer.mozilla.org/en-US/docs/Web/API
File system APIhttps://developer.mozilla.org/en-US/docs/Web/API/File_System_API
Fetch APIhttps://developer.mozilla.org/en-US/docs/Web/API/Fetch_API
Geolocation APIhttps://developer.mozilla.org/en-US/docs/Web/API/Geolocation_API
HTML DOM APIhttps://developer.mozilla.org/en-US/docs/Web/API/HTML_DOM_API
Push APIhttps://developer.mozilla.org/en-US/docs/Web/API/Push_API
Service worker APIhttps://developer.mozilla.org/en-US/docs/Web/API/Service_Worker_API
See all…https://developer.mozilla.org/en-US/docs/Web/API
Using the Web animation APIhttps://developer.mozilla.org/en-US/docs/Web/API/Web_Animations_API/Using_the_Web_Animations_API
Using the Fetch APIhttps://developer.mozilla.org/en-US/docs/Web/API/Fetch_API/Using_Fetch
Working with the History APIhttps://developer.mozilla.org/en-US/docs/Web/API/History_API/Working_with_the_History_API
Using the Web speech APIhttps://developer.mozilla.org/en-US/docs/Web/API/Web_Speech_API/Using_the_Web_Speech_API
Using web workershttps://developer.mozilla.org/en-US/docs/Web/API/Web_Workers_API/Using_web_workers
All web technologyhttps://developer.mozilla.org/en-US/docs/Web
Accessibilityhttps://developer.mozilla.org/en-US/docs/Web/Accessibility
HTTPhttps://developer.mozilla.org/en-US/docs/Web/HTTP
URIhttps://developer.mozilla.org/en-US/docs/Web/URI
Web extensionshttps://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions
WebAssemblyhttps://developer.mozilla.org/en-US/docs/WebAssembly
WebDriverhttps://developer.mozilla.org/en-US/docs/Web/WebDriver
See all…https://developer.mozilla.org/en-US/docs/Web
Mediahttps://developer.mozilla.org/en-US/docs/Web/Media
Performancehttps://developer.mozilla.org/en-US/docs/Web/Performance
Privacyhttps://developer.mozilla.org/en-US/docs/Web/Privacy
Securityhttps://developer.mozilla.org/en-US/docs/Web/Security
Progressive web appshttps://developer.mozilla.org/en-US/docs/Web/Progressive_web_apps
Learn web developmenthttps://developer.mozilla.org/en-US/docs/Learn_web_development
Getting started moduleshttps://developer.mozilla.org/en-US/docs/Learn_web_development/Getting_started
Core moduleshttps://developer.mozilla.org/en-US/docs/Learn_web_development/Core
MDN Curriculumhttps://developer.mozilla.org/en-US/curriculum/
Check out the video course from Scrimba, our partnerhttps://scrimba.com/frontend-path-c0j?via=mdn-learn-navbar
Structuring content with HTML modulehttps://developer.mozilla.org/en-US/docs/Learn_web_development/Core/Structuring_content
CSS styling basics modulehttps://developer.mozilla.org/en-US/docs/Learn_web_development/Core/Styling_basics
CSS layout modulehttps://developer.mozilla.org/en-US/docs/Learn_web_development/Core/CSS_layout
Dynamic scripting with JavaScript modulehttps://developer.mozilla.org/en-US/docs/Learn_web_development/Core/Scripting
Playgroundhttps://developer.mozilla.org/en-US/play
HTTP Observatoryhttps://developer.mozilla.org/en-US/observatory
Border-image generatorhttps://developer.mozilla.org/en-US/docs/Web/CSS/Guides/Backgrounds_and_borders/Border-image_generator
Border-radius generatorhttps://developer.mozilla.org/en-US/docs/Web/CSS/Guides/Backgrounds_and_borders/Border-radius_generator
Box-shadow generatorhttps://developer.mozilla.org/en-US/docs/Web/CSS/Guides/Backgrounds_and_borders/Box-shadow_generator
Color format converterhttps://developer.mozilla.org/en-US/docs/Web/CSS/Guides/Colors/Color_format_converter
Color mixerhttps://developer.mozilla.org/en-US/docs/Web/CSS/Guides/Colors/Color_mixer
Shape generatorhttps://developer.mozilla.org/en-US/docs/Web/CSS/Guides/Shapes/Shape_generator
About MDNhttps://developer.mozilla.org/en-US/about
Advertise with ushttps://developer.mozilla.org/en-US/advertising
Communityhttps://developer.mozilla.org/en-US/community
MDN on GitHubhttps://github.com/mdn
Bloghttps://developer.mozilla.org/en-US/blog/
WebAssemblyhttps://developer.mozilla.org/en-US/docs/WebAssembly
Guideshttps://developer.mozilla.org/en-US/docs/WebAssembly/Guides
Using the WebAssembly JavaScript APIhttps://developer.mozilla.org/en-US/docs/WebAssembly/Guides/Using_the_JavaScript_API
https://github.com/orgs/mdn/discussions/739
https://developer.mozilla.org/de/docs/WebAssembly/Guides/Using_the_JavaScript_API
https://developer.mozilla.org/en-US/docs/WebAssembly/Guides/Using_the_JavaScript_API
https://developer.mozilla.org/fr/docs/WebAssembly/Guides/Using_the_JavaScript_API
https://developer.mozilla.org/ja/docs/WebAssembly/Guides/Using_the_JavaScript_API
https://developer.mozilla.org/ko/docs/WebAssembly/Guides/Using_the_JavaScript_API
https://developer.mozilla.org/pt-BR/docs/WebAssembly/Guides/Using_the_JavaScript_API
https://developer.mozilla.org/ru/docs/WebAssembly/Guides/Using_the_JavaScript_API
https://developer.mozilla.org/zh-CN/docs/WebAssembly/Guides/Using_the_JavaScript_API
WebAssembly conceptshttps://developer.mozilla.org/en-US/docs/WebAssembly/Guides/Concepts
Loading Wasm modules in JavaScripthttps://developer.mozilla.org/en-US/docs/WebAssembly/Using_the_JavaScript_API#loading_wasm_modules_in_javascript
Memoryhttps://developer.mozilla.org/en-US/docs/WebAssembly/Using_the_JavaScript_API#memory
Tableshttps://developer.mozilla.org/en-US/docs/WebAssembly/Using_the_JavaScript_API#tables
Globalshttps://developer.mozilla.org/en-US/docs/WebAssembly/Using_the_JavaScript_API#globals
Multiplicityhttps://developer.mozilla.org/en-US/docs/WebAssembly/Using_the_JavaScript_API#multiplicity
Summaryhttps://developer.mozilla.org/en-US/docs/WebAssembly/Using_the_JavaScript_API#summary
See alsohttps://developer.mozilla.org/en-US/docs/WebAssembly/Using_the_JavaScript_API#see_also
Loading Wasm modules in JavaScripthttps://developer.mozilla.org/en-US/docs/WebAssembly/Using_the_JavaScript_API#loading_wasm_modules_in_javascript
webassembly-exampleshttps://github.com/mdn/webassembly-examples
Preparing the examplehttps://developer.mozilla.org/en-US/docs/WebAssembly/Using_the_JavaScript_API#preparing_the_example
simple.wasmhttps://raw.githubusercontent.com/mdn/webassembly-examples/master/js-api-examples/simple.wasm
simple templatehttps://github.com/mdn/webassembly-examples/blob/main/template/template.html
Converting WebAssembly format to Wasmhttps://developer.mozilla.org/en-US/docs/WebAssembly/Guides/Text_format_to_Wasm#a_first_look_at_the_text_format
Streaming the WebAssembly modulehttps://developer.mozilla.org/en-US/docs/WebAssembly/Using_the_JavaScript_API#streaming_the_webassembly_module
WebAssembly.compileStreaming()https://developer.mozilla.org/en-US/docs/WebAssembly/Reference/JavaScript_interface/compileStreaming_static
WebAssembly.instantiateStreaming()https://developer.mozilla.org/en-US/docs/WebAssembly/Reference/JavaScript_interface/instantiateStreaming_static
Responsehttps://developer.mozilla.org/en-US/docs/Web/API/Response
ArrayBufferhttps://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer
instantiate-streaming.htmlhttps://github.com/mdn/webassembly-examples/blob/main/js-api-examples/instantiate-streaming.html
view it livehttps://mdn.github.io/webassembly-examples/js-api-examples/instantiate-streaming.html
Loading our Wasm module without streaminghttps://developer.mozilla.org/en-US/docs/WebAssembly/Using_the_JavaScript_API#loading_our_wasm_module_without_streaming
WebAssembly.compile()https://developer.mozilla.org/en-US/docs/WebAssembly/Reference/JavaScript_interface/compile_static
WebAssembly.instantiate()https://developer.mozilla.org/en-US/docs/WebAssembly/Reference/JavaScript_interface/instantiate_static
ArrayBufferhttps://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer
Viewing Wasm in developer toolshttps://developer.mozilla.org/en-US/docs/WebAssembly/Using_the_JavaScript_API#viewing_wasm_in_developer_tools
Memoryhttps://developer.mozilla.org/en-US/docs/WebAssembly/Using_the_JavaScript_API#memory
Linear Memoryhttps://webassembly.github.io/spec/core/exec/index.html
load and store instructionshttps://webassembly.github.io/spec/core/exec/instructions.html#memory-instructions
shared memorieshttps://developer.mozilla.org/en-US/docs/WebAssembly/Guides/Understanding_the_text_format#shared_memories
postMessage()https://developer.mozilla.org/en-US/docs/Web/API/Window/postMessage
ArrayBufferhttps://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer
SharedArrayBufferhttps://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/SharedArrayBuffer
WebAssembly.Memory()https://developer.mozilla.org/en-US/docs/WebAssembly/Reference/JavaScript_interface/Memory
simple templatehttps://github.com/mdn/webassembly-examples/blob/main/template/template.html
Growing memoryhttps://developer.mozilla.org/en-US/docs/WebAssembly/Using_the_JavaScript_API#growing_memory
Memory.prototype.grow()https://developer.mozilla.org/en-US/docs/WebAssembly/Reference/JavaScript_interface/Memory/grow
RangeErrorhttps://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/RangeError
ArrayBufferhttps://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer
Memory.prototype.grow()https://developer.mozilla.org/en-US/docs/WebAssembly/Reference/JavaScript_interface/Memory/grow
Instance.prototype.exportshttps://developer.mozilla.org/en-US/docs/WebAssembly/Reference/JavaScript_interface/Instance/exports
More involved memory examplehttps://developer.mozilla.org/en-US/docs/WebAssembly/Using_the_JavaScript_API#more_involved_memory_example
memory.wasm.https://raw.githubusercontent.com/mdn/webassembly-examples/master/js-api-examples/memory.wasm
memory.wathttps://github.com/mdn/webassembly-examples/blob/main/js-api-examples/memory.wat
DataViewhttps://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView
Memory.prototype.bufferhttps://developer.mozilla.org/en-US/docs/WebAssembly/Reference/JavaScript_interface/Memory/buffer
memory.htmlhttps://github.com/mdn/webassembly-examples/blob/main/js-api-examples/memory.html
see it live alsohttps://mdn.github.io/webassembly-examples/js-api-examples/memory.html
Tableshttps://developer.mozilla.org/en-US/docs/WebAssembly/Using_the_JavaScript_API#tables
referenceshttps://en.wikipedia.org/wiki/Reference_(computer_science)
Table.prototype.set()https://developer.mozilla.org/en-US/docs/WebAssembly/Reference/JavaScript_interface/Table/set
Table.prototype.grow()https://developer.mozilla.org/en-US/docs/WebAssembly/Reference/JavaScript_interface/Table/grow
dynamic linking techniqueshttps://github.com/WebAssembly/tool-conventions/blob/main/DynamicLinking.md
Table.prototype.get()https://developer.mozilla.org/en-US/docs/WebAssembly/Reference/JavaScript_interface/Table/get
A table examplehttps://developer.mozilla.org/en-US/docs/WebAssembly/Using_the_JavaScript_API#a_table_example
table.wasmhttps://raw.githubusercontent.com/mdn/webassembly-examples/master/js-api-examples/table.wasm
table.wathttps://github.com/mdn/webassembly-examples/blob/main/js-api-examples/table.wat
HTML templatehttps://github.com/mdn/webassembly-examples/blob/main/template/template.html