Tests
Test: broken-expression
Template
{% raw %}{{ x }{% endraw %}
Output Django (error) v1.10.1
Invalid block tag on line 1: 'raw'. Did you forget to register or load this tag?
Output Jinja2 v2.8.0
{{ x }
Output Liquid v3.0.6
{{ x }
Output Nunjucks v2.5.0
{{ x }
Output Swig v1.4.2
{{ x }
Output Twig v1.24.2
{{ x }
Output Twigjs v0.9.5
{{ x }
Test: broken-tag
Template
{% raw %}{% if im_broken }still work{% endraw %}
Output Django (error) v1.10.1
Invalid block tag on line 1: 'raw'. Did you forget to register or load this tag?
Output Jinja2 v2.8.0
{% if im_broken }still work
Output Liquid v3.0.6
{% if im_broken }still work
Output Nunjucks v2.5.0
{% if im_broken }still work
Output Swig v1.4.2
{% if im_broken }still work{% endraw %}
Output Twig v1.24.2
{% if im_broken }still work
Output Twigjs v0.9.5
{% if im_broken }still work
Test: comment
Template
{% raw %}{# test {% endraw %}
Output Jinja2 v2.8.0
{# test
Output Liquid v3.0.6
{# test
Output Nunjucks v2.5.0
{# test
Output Swig v1.4.2
{# test
Output Twig v1.24.2
{# test
Output Twigjs v0.9.5
{# test
Test: multiline
Template
{% raw %}{{ varX }}{% endraw %}
{{ varY }}
{% raw %}
{{ varZ }}
{% endraw %}
Data
{
"varX": "value X",
"varY": "value Y",
"varZ": "value Z"
}
Output Django (error) v1.10.1
Invalid block tag on line 2: 'raw'. Did you forget to register or load this tag?
Output Jinja2 v2.8.0
{{ varX }}
value Y
{{ varZ }}
Output Liquid v3.0.6
{{ varX }}
value Y
{{ varZ }}
Output Nunjucks v2.5.0
{{ varX }}
value Y
{{ varZ }}
Output Swig v1.4.2
{{ varX }}
value Y
{{ varZ }}
Output Twig v1.24.2
{{ varX }}
value Y
{{ varZ }}
Output Twigjs v0.9.5
{{ varX }}
value Y
{{ varZ }}
Test: multiple
Template
{% raw %}{{ varX }}{% endraw %}{{ varY }}{% raw %}{{ varZ }}{% endraw %}
Data
{
"varX": "value X",
"varY": "value Y",
"varZ": "value Z"
}
Output Django (error) v1.10.1
Invalid block tag on line 1: 'raw'. Did you forget to register or load this tag?
Output Jinja2 v2.8.0
{{ varX }}value Y{{ varZ }}
Output Liquid v3.0.6
{{ varX }}value Y{{ varZ }}
Output Nunjucks v2.5.0
{{ varX }}value Y{{ varZ }}
Output Swig v1.4.2
{{ varX }}value Y{{ varZ }}
Output Twig v1.24.2
{{ varX }}value Y{{ varZ }}
Output Twigjs v0.9.5
{{ varX }}value Y{{ varZ }}
Test: nested-raw
Template
{% raw %}{% raw %}{{ x }{% endraw %}{% endraw %}
Output Django (error) v1.10.1
Invalid block tag on line 1: 'raw'. Did you forget to register or load this tag?
Output Jinja2 (error) v2.8.0
Encountered unknown tag 'endraw'.
Output Liquid (error) v3.0.6
Liquid syntax error: Unknown tag 'endraw'
Output Nunjucks v2.5.0
{% raw %}{{ x }{% endraw %}
Output Swig (error) v1.4.2
Unexpected end of tag "raw".
Output Twig (error) v1.24.2
Unknown "endraw" tag.
Output Twigjs (error) v0.9.5
TypeError: Cannot read property 'forEach' of undefined
Test: tag
Template
{% raw %}hello {{ {% %} }}{% endraw %}
Output Django (error) v1.10.1
Invalid block tag on line 1: 'raw'. Did you forget to register or load this tag?
Output Jinja2 v2.8.0
hello {{ {% %} }}
Output Liquid v3.0.6
hello {{ {% %} }}
Output Nunjucks v2.5.0
hello {{ {% %} }}
Output Swig v1.4.2
hello {{ {% %} }}
Output Twig v1.24.2
hello {{ {% %} }}
Output Twigjs v0.9.5
hello {{ {% %} }}
Test: text
Template
{% raw %}abc{% endraw %}
Output Django (error) v1.10.1
Invalid block tag on line 1: 'raw'. Did you forget to register or load this tag?
Output Jinja2 v2.8.0
abc
Output Liquid v3.0.6
abc
Output Nunjucks v2.5.0
abc
Output Swig v1.4.2
abc
Output Twig v1.24.2
abc
Output Twigjs v0.9.5
abc
Output Django (error) v1.10.1