diff --git a/_includes/baselayout.njk b/_includes/baselayout.njk new file mode 100644 index 0000000..eef001a --- /dev/null +++ b/_includes/baselayout.njk @@ -0,0 +1,38 @@ + + + + + + {{ title }} + + + +
+
+
+
+
+ {% block header %} +
+ {{ content | safe }} +
+ {% endblock %} + {% block main %} + Main + {% endblock %} + + {% block footer %} + {% endblock %} + + +
+
+ + diff --git a/_includes/indexlayout.njk b/_includes/indexlayout.njk index 1ee6017..2ac22ec 100644 --- a/_includes/indexlayout.njk +++ b/_includes/indexlayout.njk @@ -5,109 +5,88 @@ pagination: alias: posts reverse: true --- - - - - - - {{ title }} - - - -
-
-
+ +{% extends "baselayout.njk" %} + +{% block main %} +
+ {%- for post in posts -%} +
+ -
-
- {{ content | safe }} +
+ -
- {%- for post in posts -%} -
-
- - - -
-
- -
-
- -
-
- - {{ post.templateContent | emojiReadTime }} - -
-
-
-
- {%- endfor -%} +
+
+ +
+
+ + {{ post.templateContent | emojiReadTime }} + +
- -
- - + {%- endfor -%} +
+{% endblock %} + +{% block footer %} + +{% endblock %} diff --git a/_includes/postlayout.njk b/_includes/postlayout.njk new file mode 100644 index 0000000..829347c --- /dev/null +++ b/_includes/postlayout.njk @@ -0,0 +1,32 @@ +{% extends "baselayout.njk" %} + +{% block header %} +
+

{{ title }}

+

{{ description }}

+ +
+
+ +
+
+ + {{ content | emojiReadTime }} + +
+
+
+{% endblock %} + +{% block main %} +
+
+ +
+
+ {{ content | safe }} +
+{% endblock %} + diff --git a/content/posts/posts.json b/content/posts/posts.json new file mode 100644 index 0000000..ed76082 --- /dev/null +++ b/content/posts/posts.json @@ -0,0 +1 @@ +{ "layout": "postlayout.njk" }