trait DioxusElement { const TAG_NAME: &'static str; const NAME_SPACE: Option<&'static str>; } struct myinput {} struct NodeBuilder {} impl NodeBuilder { // fn add_attr() } macro_rules! builder_constructors { ( $( $(#[$attr:meta])* $name:ident; // { // attrs: [ // $( // $(#[$attr2:meta])* // $attr3:ident // , // )* // ]; // } )* ) => { $( #[allow(non_camel_case_types)] $(#[$attr])* pub struct $name<'a> { // the we wrap the builder, shielding what can be added builder: &'a NodeBuilder } impl<'a> DioxusElement for $name<'a> { const TAG_NAME: &'static str = stringify!($name); const NAME_SPACE: Option<&'static str> = None; } )* }; ( $( $(#[$attr:meta])* $name:ident <> $namespace:tt; )* ) => {}; } // Organized in the same order as // https://developer.mozilla.org/en-US/docs/Web/HTML/Element // // Does not include obsolete elements. builder_constructors! { // Document metadata /// Build a /// [``](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/base) /// element. /// /// A base element is your mom! base; /// Build a /// [``](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/head) /// element. head; /// Build a /// [``](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/link) /// element. link; /// Build a /// [``](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/meta) /// element. meta; /// Build a /// [`