{"repo":"utkarshkukreti/markup.rs","free":true,"listed":false,"github":"https://github.com/utkarshkukreti/markup.rs","clone":"git clone https://github.com/utkarshkukreti/markup.rs.git","description":"A blazing fast, type-safe template engine for Rust.","language":"Rust","stars":399,"topics":["rust","template-engine","template","html","markup","pug","haml","slim"],"license":"Apache-2.0","category":"saas-starters-boilerplates","readme_excerpt":"markup.rs A blazing fast, type-safe template engine for Rust. markup.rs is a template engine for Rust powered by procedural macros which parses the template at compile time and generates optimal Rust code to render the template at run time. The templates may embed Rust code which is type checked by the Rust compiler enabling full type-safety. Features Fully type-safe with inline highlighted errors when using editor extensions like rust-analyzer. Less error-prone and terse syntax inspired by Haml, Slim, and Pug. Zero unsafe code. Zero runtime dependencies. ⚡ Blazing fast. The fastest in this benchmark among the ones which do not use unsafe code, the second fastest overall. Install Framework Integration We have integration examples for the following web frameworks: 1. Axum 2. Rocket Quick Example Output Output (manually prettified) Syntax Reference (WIP) markup::define! and markup::new! There are two ways to define templates: markup::define! and markup::new! . markup::define! defines a template with named arguments. These templates cannot access variables from outer scope. The templates can have generic parameters. Under the hood, markup::define! compiles to a Rust struct that implements markup::Render and std::fmt::Display traits. Code Output markup::new! defines a template without any arguments. These can access variables from outer scope. Code Output Expressions Templates can have bare literal values, which are rendered as is. They can also have expressions (including functi","default_branch":null,"files":null,"tree":[],"storefront":"/r/utkarshkukreti","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/utkarshkukreti/markup.rs/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}