aboutsummaryrefslogtreecommitdiff
path: root/vim/bundle/vim-snippets/snippets/twig.snippets
blob: 47997c3b2168eb1e098f417b592d5ea554a3047a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
snippet bl "{% block xyz %} .. {% endblock xyz %}"
	{% block ${1} %}
	${2}
	{% endblock $1 %}
snippet js "{% javascripts 'xyz' %} .. {% endjavascripts %}"
	{% javascripts '${1}' %}
		<script src="{{ asset_url }}"></script>
	{% endjavascripts %}
snippet css "{% stylesheets 'xyz' %} .. {% endstylesheets %}"
	{% stylesheets '${1}' %}
		<link rel="stylesheet" href="{{ asset_url }}">
	{% endstylesheets %}
snippet if "{% if %} .. {% endif %}"
	{% if ${1} %}
	${2}
	{% endif %}
snippet ife "{% if %} .. {% else %} .. {% endif %}"
	{% if ${1} %}
	${2}
	{% else %}
	${0}
	{% endif %}
snippet el "{% else %}"
	{% else %}
	${0}
snippet eif "{% elseif %}"
	{% elseif ${1} %}
	${0}
snippet for "{% for x in y %} .. {% endfor %}"
	{% for ${1} in ${2} %}
	${3}
	{% endfor %}
snippet ext "{% extends xyz %}"
	{% extends ${1} %}