Skip to main content

from_wire_type

Function from_wire_type 

Source
pub(crate) fn from_wire_type(ty: &Type) -> TokenStream
Expand description

The type JavaScript passes for a parameter of type ty.

#[wasm_record] and #[wasm_object] implement FromWasm at each type’s declaration site, so this resolves to Ts<T> for a serde DTO and to T for a #[wasm_bindgen] handle. A type that has declared neither is a missing-impl error naming the site.