composable-html 0.1.0-1

composable-html is a Rust crate that allows you to define and compose HTML elements in a flexible, declarative way. It also contains optional general-purpose HTML elements.
Documentation
  • Coverage
  • 100%
    14 out of 14 items documented1 out of 10 items with examples
  • Size
  • Source code size: 13.73 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 1.74 MB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 13s Average build duration of successful builds.
  • all releases: 13s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • asperan/composable-html
    0 0 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • asperan

composable-html

composable-html is a Rust crate that allows you to define and compose HTML elements in a flexible, declarative way. It contains general-purpose HTML elements, which can be enabled using the elements feature flag (which is off by default).

Install

To install the composable-html crate, you can add it as a dependency in your Cargo.toml file.

Manually

Add the following line to your Cargo.toml under [dependencies] (<version> must be replaced with the correct version reference):

[dependencies]
composable-html = "<version>"

If you want to enable the "elements" feature (to include general-purpose HTML elements), add it like this:

[dependencies]
composable-html = { version = "<version>", features = ["elements"] }

Cargo

Alternatively, you can add the crate using the cargo command:

cargo add composable-html

To enable the "elements" feature flag, use:

cargo add composable-html --features elements

Usage

To define a new composable element, create a struct that implements the Render trait. You can find examples in the elements module.

Contributing

Contributions are welcome! If you'd like to contribute, feel free to fork the repository and submit a pull request. Please ensure that your code follows the Rust style and includes tests for any new functionality.

For bug reports or feature requests, please open an issue in the GitHub repository.

License

This project is licensed under the MIT License. See the LICENSE file for more details.