dioxus_html/
lib.rs

1#![doc = include_str!("../README.md")]
2#![doc(html_logo_url = "https://avatars.githubusercontent.com/u/79236386")]
3#![doc(html_favicon_url = "https://avatars.githubusercontent.com/u/79236386")]
4#![allow(non_snake_case)]
5
6//! # Dioxus Namespace for HTML
7//!
8//! This crate provides a set of compile-time correct HTML elements that can be used with the Rsx and Html macros.
9//! This system allows users to easily build new tags, new types, and customize the output of the Rsx and Html macros.
10//!
11//! An added benefit of this approach is the ability to lend comprehensive documentation on how to use these elements inside
12//! of the Rsx and Html macros. Each element comes with a substantial amount of documentation on how to best use it, hopefully
13//! making the development cycle quick.
14//!
15//! All elements are used as zero-sized unit structs with trait impls.
16//!
17//! Currently, we don't validate for structures, but do validate attributes.
18
19pub mod elements;
20#[cfg(feature = "hot-reload-context")]
21pub use elements::HtmlCtx;
22#[cfg(feature = "html-to-rsx")]
23pub use elements::{map_html_attribute_to_rsx, map_html_element_to_rsx};
24pub mod events;
25pub(crate) mod file_data;
26pub use file_data::*;
27mod attribute_groups;
28pub mod geometry;
29pub mod input_data;
30pub mod point_interaction;
31mod render_template;
32
33#[cfg(feature = "serialize")]
34mod transit;
35
36#[cfg(feature = "serialize")]
37pub use transit::*;
38
39pub use attribute_groups::*;
40pub use elements::*;
41pub use events::*;
42pub use render_template::*;
43
44pub mod extensions {
45    pub use crate::attribute_groups::{GlobalAttributesExtension, SvgAttributesExtension};
46    pub use crate::elements::extensions::*;
47}
48
49pub mod prelude {
50    pub use crate::attribute_groups::{GlobalAttributesExtension, SvgAttributesExtension};
51    pub use crate::elements::extensions::*;
52    pub use crate::events::*;
53    pub use crate::point_interaction::*;
54    pub use keyboard_types::{self, Code, Key, Location, Modifiers};
55}