worker_plus_sys/
dynamic_dispatch.rs

1use wasm_bindgen::prelude::*;
2
3use crate::fetcher::Fetcher;
4
5#[wasm_bindgen]
6extern "C" {
7    #[wasm_bindgen(extends = ::js_sys::Object, js_name = DynamicDispatcher)]
8    #[derive(Debug, Clone, PartialEq, Eq)]
9    pub type DynamicDispatcher;
10
11    #[wasm_bindgen(structural, method, js_class=DynamicDispatcher, js_name = get, catch)]
12    pub fn get(
13        this: &DynamicDispatcher,
14        name: String,
15        options: JsValue,
16    ) -> Result<Fetcher, JsValue>;
17}