Permalink
Browse files

Add twig support (#265)

  • Loading branch information...
ahmedelgabri authored and Aaronepower committed Sep 22, 2018
1 parent eea0fe0 commit 6f84d85ae86998e5d4378e265d11b2fc7a35f4df
Showing with 30 additions and 0 deletions.
  1. +14 −0 languages.json
  2. +16 −0 tests/data/twig.twig
View
@@ -1434,6 +1434,20 @@
"toml"
]
},
"Twig": {
"name":"Twig",
"base":"html",
"quotes":[
["\\\"", "\\\""],
["'", "'"]
],
"extensions":[
"twig"
],
"multi_line":[
["{#", "#}"]
]
},
"TypeScript":{
"base":"c",
"quotes":[
View
@@ -0,0 +1,16 @@
{# 16 lines 14 code 1 comments 1 blanks #}
<ul id="product-collection">
{% for product in products %}
<li class="singleproduct clearfix">
<div class="small">
<div class="prodimage"><a href="{{product.url}}"><img src="{{ product.featured_image | url }}" /></a></div>
</div>
<div class="description">
<h3><a href="{{product.url}}">{{- product.title -}}</a></h3>
<p>{{ product.description | capitalize }}</p>
<p class="money">{{ product.price_min | default('0') }}{% if product.price_varies %} - {{ product.price_max | number_format(2, '.', ',') }}{% endif %}</p>
</div>
</li>
{% endfor %}
</ul>

0 comments on commit 6f84d85

Please sign in to comment.