1
0
Fork 0
mirror of https://github.com/Luzifer/nginx-sso.git synced 2024-12-30 01:31:18 +00:00
nginx-sso/vendor/github.com/flosch/pongo2/template_tests/whitespace_control.tpl
Knut Ahlers 9b3c895c04
Update dependencies
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2019-04-22 06:44:07 +02:00

33 lines
562 B
Smarty

Standard whitespace control:
{% if true %}
Standard whitespace control
{% endif %}
Full Trim whitespace control:
{% if true -%}
Full Trim whitespace control
{%- endif %}
Useful with logic:
{%- if false %}
1st choice
{%- elif false %}
2nd choice
{%- elif true %}
3rd choice
{%- endif %}
Cycle without whitespace control:
{% for i in simple.multiple_item_list %}
{{ i }}
{% endfor %}
Cycle with whitespace control:
{% for i in simple.multiple_item_list %}
{{- i }}
{% endfor %}
Trim everything:
{% for i in simple.multiple_item_list -%}
{{ i }}
{%- endfor %}