Trait JsFnOutput
pub trait JsFnOutput<M>: Send + 'static {
// Required method
fn into_js_fn_output(self) -> Result<JsValue, JsError>;
}Available on crate features
js and std only.Expand description
A value a host function can return: either a plain value
convertible Into<JsValue>, or a Result thereof with an
error convertible Into<JsError> (thrown inside the script).
The M parameter is an inference marker; ignore it.
Required Methods§
fn into_js_fn_output(self) -> Result<JsValue, JsError>
fn into_js_fn_output(self) -> Result<JsValue, JsError>
Convert into the raw host function output.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".