pub trait AsNode {
// Required method
fn as_node(&self) -> Option<VirtualNode>;
}Expand description
Trait for types that can be converted into a VirtualNode for use in HTML expressions.
Implemented by primitive types, strings, and signals to allow seamless embedding in HTML markup.
Required Methods§
Sourcefn as_node(&self) -> Option<VirtualNode>
fn as_node(&self) -> Option<VirtualNode>
Converts this value into a VirtualNode, if possible.
Implementations on Foreign Types§
Source§impl AsNode for &str
Converts a string slice into a text virtual node.
impl AsNode for &str
Converts a string slice into a text virtual node.
fn as_node(&self) -> Option<VirtualNode>
Source§impl AsNode for bool
Converts a bool into a text virtual node.
impl AsNode for bool
Converts a bool into a text virtual node.
fn as_node(&self) -> Option<VirtualNode>
Source§impl AsNode for f32
Converts an f32 into a text virtual node.
impl AsNode for f32
Converts an f32 into a text virtual node.
fn as_node(&self) -> Option<VirtualNode>
Source§impl AsNode for f64
Converts an f64 into a text virtual node.
impl AsNode for f64
Converts an f64 into a text virtual node.
fn as_node(&self) -> Option<VirtualNode>
Source§impl AsNode for i32
Converts an i32 into a text virtual node.
impl AsNode for i32
Converts an i32 into a text virtual node.
fn as_node(&self) -> Option<VirtualNode>
Source§impl AsNode for i64
Converts an i64 into a text virtual node.
impl AsNode for i64
Converts an i64 into a text virtual node.
fn as_node(&self) -> Option<VirtualNode>
Source§impl AsNode for usize
Converts a usize into a text virtual node.
impl AsNode for usize
Converts a usize into a text virtual node.
fn as_node(&self) -> Option<VirtualNode>
Source§impl AsNode for String
Converts a String into a text virtual node.
impl AsNode for String
Converts a String into a text virtual node.