I am working on a jinja2 template in python where autoescape=true flag is required due to privacy constraint.
Since the autoescaping is enabled, jinja template ouputs the ascii value i.e >> instead of >> symbols.
Is their a way where I can still output the > sign while still enabling the autoescape flag?
item: abcd >> efgh
Sample Jinja2 template:
{{ item }}
Current output: abcd >> efgh
Expected output: abcd >> efgh
Expected output: abcd >> efgh
You can manually mark a specific variable as safe with the
safefilter:But then you need to make sure that
itemdoes not contain any harmful content (replace them manually).