Debian Codegraph @

examples/prism-twig.html

raw symbols SCIP
1 <h2>Comments</h2>
2 <pre><code>{# Some comment
3 on multiple lines
4 with &lt;html>&lt;/html>
5 inside #}</code></pre>
6
7 <h2>Keywords</h2>
8 <pre><code>{% if foo %} bar {% endif %}
9 {% for key, value in arr if value %} {{ do_something() }} {% endfor %}
10 {% include 'header.html' %}
11 {% include 'template.html' with {'foo': 'bar'} %}</code></pre>
12
13 <h2>Operators</h2>
14 <pre><code>{{ not a }}
15 {{ 20 // 7 }}
16 {{ b b-and c }}
17 {% if phone matches '/^[\\d\\.]+$/' %} ... {% endif %}</code></pre>
18
19 <h2>Twig embedded in HTML</h2>
20 <pre><code>&lt;div>
21 {% if foo %}
22 &lt;p>Foo!&lt;/p>
23 {% else %}
24 &lt;p>Not foo...&lt;/p>
25 {% endif %}</code></pre>