handlebars::EscapeFn [] [src]

type EscapeFn = Box<Fn(&str) -> String + Send + Sync>;

This type represents an escape fn, that is a function who's purpose it is to escape potentially problematic characters in a string.

The default escape fn replaces the characters &"<> with the equivalent html / xml entities.

An escape fn is represented as a Box to avoid unnecessary type parameters (and because traits cannot be aliased using type).