Glench / Vim-Jinja2-Syntax

An up-to-date jinja2 syntax file.
https://github.com/mitsuhiko/jinja2
BSD 3-Clause "New" or "Revised" License
343 stars 64 forks source link

Add support for whitespace control in ftdetect #8

Closed SegFaultAX closed 10 years ago

SegFaultAX commented 10 years ago

Docs: http://jinja.pocoo.org/docs/templates/#whitespace-control

Whitespace can be controlled before and after jinja tags by adding a - to the appropriate jinja block marker.

{% for i in [1,2,3] %}
  # ... SNIP ...
{% endfor %}

becomes

{% for i in [1,2,3] -%}
  # ... SNIP ...
{%- endfor %}
Glench commented 10 years ago

Thanks!