Getting started with zola

This commit is contained in:
2023-08-07 21:46:46 +03:00
parent 669debc66c
commit 8499ee2230
10 changed files with 61 additions and 0 deletions
+1
View File
@@ -0,0 +1 @@
*.html
View File
+6
View File
@@ -0,0 +1,6 @@
+++
title = "List of blog posts"
sort_by = "date"
template = "blog.html"
page_template = "blog-page.html"
+++
+6
View File
@@ -0,0 +1,6 @@
+++
title = "My first post"
date = 2023-08-01
+++
This is my first blog post
+6
View File
@@ -0,0 +1,6 @@
+++
title = "My second post"
date = 2023-08-07
+++
This is my second blog post.
View File
+13
View File
@@ -0,0 +1,13 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Ian Andwati</title>
</head>
<body>
<section class="section">
<div class="container">{% block content %}{% endblock %}</div>
</section>
</body>
</html>
+9
View File
@@ -0,0 +1,9 @@
{% extends 'base.html' %}
{% block content %}
<h1 class="title">
{{ page.title}}
</h1>
<p class="subtitle"><strong>{{ page.date }}</strong></p>
{{ page.content | safe }}
{% endblock content %}
+14
View File
@@ -0,0 +1,14 @@
{% extends 'base.html' %}
{% block content %}
<h1 class="title">
{{ section.title}}
</h1>
<ul>
<!-- If you are using pagination, section.pages will be empty. You need to use the paginator object -->
{% for page in section.pages %}
<li><a href="{{ page.permalink | safe }}">{{ page.title }}</a></li>
{% endfor %}
</ul>
{% endblock content %}
+6
View File
@@ -0,0 +1,6 @@
{% extends 'base.html' %}
{% block content %}
<h1 class="title">This is my blog made with zola</h1>
<p>Click <a href="{{ get_url(path='@/blog/_index.md')}}">here</a> to see my posts</p>
{% endblock content %}