Struct rustcn_ui::dioxus_core::VComponent
source · pub struct VComponent {
pub name: &'static str,
/* private fields */
}Expand description
An instance of a child component
Fields§
§name: &'static strThe name of this component
Implementations§
source§impl VComponent
impl VComponent
sourcepub fn new<P, M>(
component: impl ComponentFunction<P, M>,
props: P,
fn_name: &'static str
) -> VComponentwhere
M: 'static,
P: Properties + 'static,
pub fn new<P, M>(
component: impl ComponentFunction<P, M>,
props: P,
fn_name: &'static str
) -> VComponentwhere
M: 'static,
P: Properties + 'static,
Create a new VComponent variant
sourcepub fn mounted_scope<'a>(
&self,
dynamic_node_index: usize,
vnode: &VNode,
dom: &'a VirtualDom
) -> Option<&'a ScopeState>
pub fn mounted_scope<'a>( &self, dynamic_node_index: usize, vnode: &VNode, dom: &'a VirtualDom ) -> Option<&'a ScopeState>
Get the scope this node is mounted to if it’s mounted
This is useful for rendering nodes outside of the VirtualDom, such as in SSR
Returns None if the node is not mounted
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for VComponent
impl !Send for VComponent
impl !Sync for VComponent
impl Unpin for VComponent
impl !UnwindSafe for VComponent
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T, O> SuperFrom<T> for Owhere
O: From<T>,
impl<T, O> SuperFrom<T> for Owhere
O: From<T>,
source§fn super_from(input: T) -> O
fn super_from(input: T) -> O
Convert from a type to another type.
source§impl<T, O, M> SuperInto<O, M> for Twhere
O: SuperFrom<T, M>,
impl<T, O, M> SuperInto<O, M> for Twhere
O: SuperFrom<T, M>,
source§fn super_into(self) -> O
fn super_into(self) -> O
Convert from a type to another type.