nickel-org / rust-mustache

mustache template library for rust
Other
202 stars 61 forks source link

Add support for providing partials in data #80

Open cdhowie opened 1 year ago

cdhowie commented 1 year ago

This patch adds Data::Template, which allows partials to be provided and/or overridden by the rendered data. In our case, we need to be able to determine the template for a partial dynamically. This allows us to do that, as well as provide a "default" partial and replace it at runtime if needed.