Expand description
WebUI Handler implementation for Rust.
This crate provides functionality to process and render WebUI protocols into final HTML output based on provided data.
Modules§
- css_
module - Shared helpers for emitting CSS module definitions as
<script type="importmap">tags withdata:text/css,…URIs. - plugin
- Handler plugin trait and built-in plugin implementations.
- route_
handler - Route component inventory management for incremental route rendering.
- route_
matcher - Iterative path template matcher for server-side route resolution.
Structs§
- Render
Options - Options controlling how the handler renders a protocol.
- WebUI
Handler - The main WebUI handler that processes protocols and renders them.
Enums§
- Handler
Error - Error types for the WebUI handler.
Traits§
- Response
Writer - Interface for writing rendered output
Functions§
- encode_
safe - Minimal HTML escaper for the 6 XSS-critical characters
(
& < > " ' /). ReturnsCow::Borrowedwhen no escaping is needed (zero allocation on the happy path),Cow::Ownedwhen any character had to be replaced. - handle
- Process a WebUI protocol with the provided state and write the output to the given writer. This is the main entry point for the WebUI handler.