boilerplateboilerplate is a minimal compile-time Rust text template engine.
boilerplate's HTML escaping has not been scrutinized, and should not be used
in production environments with untrusted input.
Add boilerplate to your project's Cargo.toml:
toml
[dependencies]
boilerplate = "*"
Create a template in templates/my-template.txt:
text
Foo is {{self.n}}!
Define, instantiate, and render the template context:
```rust use boilerplate::Boilerplate;
struct MyTemplate { n: u32, }
asserteq!(MyTemplate { n: 10 }.tostring(), "Foo is 10!\n"); ```
See the docs for more information and examples.