I using Jinja2 with webapp2.
Jinja2 encodes all \'context\' data into unicode as their doc says. This is proving problematic when I try to insert a json string into
In Jinja 2.9 I followed @Xion's advice to first convert the iterable elements to string using map('string'). The map filter result I then converted to a list which is finally output as JSON using the tojson built-in filter.
map('string')
tojson
{{ jsonData|map('string')|list|tojson }}