Skip to main content

Module escape

Module escape 

Source
Expand description

HTML and attribute string escaping helpers.

Functionsยง

escape_attr
Escapes characters unsafe within an HTML attribute value (<, >, &, "), returning the input unchanged (borrowed) when no escaping is needed.
escape_html
Escapes characters unsafe within HTML text content (<, >, &), returning the input unchanged (borrowed) when no escaping is needed.