-
Notifications
You must be signed in to change notification settings - Fork 0
/
jinja2.html
30 lines (30 loc) · 1.44 KB
/
jinja2.html
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
<!DOCTYPE html>
<html>
<head>
<title>Jinja2</title>
<meta charset="UTF-8">
<link href="./css/stylesheet.css" rel="stylesheet">
</head>
<body>
<section>
<h1>Jinja2</h1>
<p>Jinja2 is a templating language with syntax similar to Django.</p>
<div>
<h2>Code Sample</h2>
<div class="code_sample">
<code>
<pre><span class="token">{%</span> <span class="key_word">extends</span> <span class="code">"layout.html"</span> <span class="token">%}</span>
<span class="token">{%</span> <span class="key_word">block</span> <span class="code">body</span> <span class="token">%}</span>
<ul>
<span class="token">{%</span> <span class="key_word">for</span> <span class="code">user</span> <span class="key_word">in</span> <span class="code">users</span> <span class="token">%}</span>
<li><a href="<span class="token">{{</span> <span class="code">user.url</span> <span class="token">}}</span>"><span class="token">{{</span> <span class="code">user.username</span> <span class="token">}}</span></a></li>
<span class="token">{%</span> <span class="key_word">endfor</span> <span class="token">%}</span>
</ul>
<span class="token">{%</span> <span class="key_word">endblock</span> <span class="token">%}</span></pre>
</code>
</div>
</div>
</section>
<script data-main="js/main" src="js/require.js"></script>
</body>
</html>