Expand description
A text template engine based on Jinja2.
See crate ::tera
.
Modules§
Macros§
- try_
get_ value - Helper macro to get real values out of Value while retaining proper errors in filters
Structs§
- Context
- The struct that holds the context of a template rendering.
- Error
- The Error type
- Map
- Represents a JSON key/value type.
- Number
- Represents a JSON number, whether integer or floating point.
- Template
- This is the parsed equivalent of a template file. It also does some pre-processing to ensure it does as little as possible at runtime Not meant to be used directly.
- Tera
- Main point of interaction in this library.
Enums§
Traits§
- Filter
- The filter function type definition
- Function
- The global function type definition
- Test
- The tester function type definition
Functions§
- dotted_
pointer - Lookups a dotted path in a json value contrary to the json slash pointer it’s not allowed to begin with a dot
- escape_
html - Escape HTML following OWASP
- from_
value - Interpret a
serde_json::Value
as an instance of typeT
. - get_
json_ pointer Deprecated - Converts a dotted path to a json pointer one
- to_
value - Convert a
T
intoserde_json::Value
which is an enum that can represent any valid JSON data.
Type Aliases§
- Result
- Convenient wrapper around std::Result.