8 releases

0.3.0 Apr 6, 2023
0.2.1 Apr 2, 2023
0.1.4 Apr 2, 2023
0.1.3 Dec 12, 2021
0.1.0 Nov 26, 2021

#73 in #transformation


Used in laby

MIT license

80KB
2K SLoC

laby

Crate Docs Maintainer License Issues Contributors

laby is a small macro library for writing HTML templates in Rust. Documentation

let n = html!(
  head!(
    title!("laby"),
  ),
  body!(
    p!("Hello, world!"),
  ),
);

let s = render!(DocType::HTML5, n);
<!DOCTYPE html><html><head><title>laby</title></head><body><p>Hello, world!</p></body></html>

lib.rs:

Contains macros that generate specialized HTML rendering code.

This crate is re-exported by crate laby. If you are using laby, you should not depend on this crate directly.

Dependencies

~2MB
~45K SLoC