pub trait ToHtml {
// Required method
fn to_html(&self) -> VNode;
// Provided method
fn into_html(self) -> VNode
where Self: Sized { ... }
}
Expand description
A trait implemented for types be rendered as a part of a Html.
Types that implements this trait can define a virtual dom layout that itself should be rendered
into via html!
and can be referenced / consumed as {value}
in an html!
macro invocation.