link_to

Macro link_to 

Source
link_to!() { /* proc-macro */ }
Expand description

Link to a JS file for use with workers/worklets.

This macro is only meaningful in WASM contexts. When running outside of WASM, it will panic at runtime.

§Example

use web_sys::Worker;
let worker = Worker::new(&wasm_bindgen::link_to!(module = "/src/worker.js"));