Crate ic_wasm_bindgen

source ·
Expand description

Runtime support for the wasm-bindgen tool

This crate contains the runtime support necessary for wasm-bindgen the attribute and tool. Crates pull in the #[wasm_bindgen] attribute through this crate and this crate also provides JS bindings through the JsValue interface.

Re-exports

  • pub use crate::cast::JsObject;

Modules

  • Support for long-lived closures in wasm-bindgen
  • This is mostly an internal module, no stability guarantees are provided. Use at your own risk.
  • A module which is typically glob imported.

Macros

  • This macro takes a JS module as input and returns a URL that can be used to access it at runtime.

Structs

  • A wrapper type around slices and vectors for binding the Uint8ClampedArray array in JS.
  • Convenience type for use on exported fn() -> Result<T, JsError> functions, where you wish to throw a JavaScript Error object.
  • Wrapper type for imported statics.
  • Representation of an object owned by JS.

Traits

  • A trait for checked and unchecked casting between JS types.
  • An extension trait for Option<T> and Result<T, E> for unwrapping the T value, or throwing a JS error if it is not available.

Functions