MDN self-hosted library · e01.org

WebAssembly.SuspendError

Runnable notebook: every JavaScript, HTML and CSS example on this page executes in a sandboxed local frame. Nothing leaves the browser.

js
try {
  throw new WebAssembly.SuspendError("Hello", "someFile", 10);
} catch (e) {
  console.log(e instanceof WebAssembly.SuspendError); // true
  console.log(e.message); // "Hello"
  console.log(e.name); // "SuspendError"
  console.log(e.fileName); // "someFile"
  console.log(e.lineNumber); // 10
  console.log(e.columnNumber); // 0
  console.log(e.stack); // The location where the code was run
}