pub fn trim<T: Display>(s: T) -> Result<String>Expand description
Strip leading and trailing whitespace
/// ```jinja
/// <div>{{ example|trim }}</div>
/// ```
#[derive(Template)]
#[template(ext = "html", in_doc = true)]
struct Example<'a> {
example: &'a str,
}
assert_eq!(
Example { example: " Hello\tworld\t" }.to_string(),
"<div>Hello\tworld</div>"
);