html!() { /* proc-macro */ }
Expand description

Converts HTML to String.

Values returned from braced blocks {} are expected to return something that implements Display.

See syn-rsx docs for supported tags and syntax.

Example

use html_to_string_macro::html;

let world = "planet";
assert_eq!(html!(<div>"hello "{world}</div>), "<div>hello planet</div>");