pub trait DioxusElement {
    const TAG_NAME: &'static str;
    const NAME_SPACE: Option<&'static str>;

    fn tag_name(&self) -> &'static str { ... }
    fn namespace(&self) -> Option<&'static str> { ... }
}
Expand description

A trait for any generic Dioxus Element.

This trait provides the ability to use custom elements in the rsx! macro.

struct my_element;

impl DioxusElement for my_element {
    const TAG_NAME: "my_element";
    const NAME_SPACE: None;
}

let _ = rsx!{
    my_element {}
};

Required Associated Constants

The tag name of the element.

The namespace of the element.

Provided Methods

The tag name of the element.

The namespace of the element.

Implementors

impl DioxusElement for article