File: index.html

package info (click to toggle)
staticsite 2.5-1
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 14,648 kB
  • sloc: javascript: 33,722; python: 9,851; makefile: 46; sh: 4
file content (33 lines) | stat: -rw-r--r-- 802 bytes parent folder | download | duplicates (2)
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
{% extends "base.html" %}

{% block front_matter %}
---
# Author of the website
author: Example author

# Absolute URL to the root of the website
site_url: "https://www.example.org"
{% endblock %}

{% block title %}Example web site{% endblock %}

{% block content %}

<h1>{{page.meta.title}}</h1>

<p>This is the content of the home page for the site.</p>

<p>You do not need to write it as Jinja2+HTML, it can be <tt>index.md</tt>
instead, depending on your needs.</p>

<p>With a Jinja2 template, you can do interesting things like this:</p>

<h2>Latest <a href="{{ url_for('/blog/index.html') }}">blog posts</a></h2>

<ul>
  {% for page in syndicated_pages("blog", limit=10) %}
  <li><a href="{{ url_for(page) }}">{{page.meta.date}}: {{page.meta.title}}</a></li>
  {% endfor %}
</ul>

{% endblock %}