Re-arrange _includes templates

This commit is contained in:
kalanggam 2023-10-19 21:05:29 -05:00
parent eb8aba3224
commit 6b8dfa650c
10 changed files with 25 additions and 24 deletions

View file

@ -1,5 +1,5 @@
module.exports = { module.exports = {
siteName: "gils.nexus", siteName: "gils.nexus",
siteDescription: "", siteDescription: "",
authorName: "", authorName: "gil",
}; };

View file

@ -1,17 +1,12 @@
<!DOCTYPE html> <!doctype html>
<html lang="en"> <html lang="en">
<head> <head>
<meta charset="UTF-8" /> <meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> <meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>{% if title %}{{ title }} | {% endif %}{{ meta.siteName }}</title> <title>{% if title %}{{ title }} | {% endif %}{{ meta.siteName }}</title>
<link rel="stylesheet" href="/css/global.css"> <link rel="stylesheet" href="/css/global.css" />
</head> </head>
<body> <body>
<header>
<h1>{{ title }}</h1>
</header>
<main>
{{ content | safe }} {{ content | safe }}
</main>
</body> </body>
</html> </html>

1
src/_includes/footer.njk Normal file
View file

@ -0,0 +1 @@
<footer></footer>

3
src/_includes/header.njk Normal file
View file

@ -0,0 +1,3 @@
<header>
<h1>{{ title or meta.siteName }}</h1>
</header>

8
src/_includes/page.njk Normal file
View file

@ -0,0 +1,8 @@
---
layout: base.njk
---
{% include "header.njk" %}
<main>
{{ content | safe }}
</main>
{% include "footer.njk" %}

View file

@ -1,6 +1,6 @@
--- ---
title: Cebuano title: Cebuano
layout: base.njk layout: page.njk
--- ---
[&larr; Home](/) [&larr; Home](/)

View file

@ -1,12 +1,9 @@
--- ---
title: gils.nexus layout: page.njk
layout: base.njk
date: Last Modified date: Last Modified
--- ---
hello! my name is gil and this is my site. pronouns are he/they. i write and hello! my name is gil and this is my site. pronouns are he/they. i write and tinker with software/hardware. i don't have much to put here except links (for now).
tinker with software/hardware. i don't have much to put here except
links (for now).
--- ---
@ -20,12 +17,9 @@ links (for now).
## Links ## Links
[hol.ogra.ph](https://hol.ogra.ph/@gil) &mdash; federated [hol.ogra.ph](https://hol.ogra.ph/@gil) &mdash; federated microblogging (i'm a co-admin here!)
microblogging (i'm a co-admin here!) [pixelfed.social](https://pixelfed.social/kalanggam) &mdash; federated photo and video sharing
[pixelfed.social](https://pixelfed.social/kalanggam) &mdash; [beehaw](https://beehaw.org/u/kalanggam) &mdash; federated link aggregator/discussions
federated photo and video sharing
[beehaw](https://beehaw.org/u/kalanggam) &mdash; federated link
aggregator/discussions
[bookwyrm.social](https://bookwyrm.social/user/kalanggam) &mdash; federated book reviews [bookwyrm.social](https://bookwyrm.social/user/kalanggam) &mdash; federated book reviews
--- ---

View file

@ -1,6 +1,6 @@
--- ---
title: Now title: Now
layout: base.njk layout: page.njk
--- ---
Hello! Hello!

View file

@ -1,6 +1,6 @@
--- ---
title: Poetry title: Poetry
layout: base.njk layout: page.njk
permalink: /poetry/index.html permalink: /poetry/index.html
override:tags: [] override:tags: []
--- ---

View file

@ -1,5 +1,5 @@
{ {
"layout": "base.njk", "layout": "page.njk",
"permalink": "/poem/{{ page.fileSlug }}/", "permalink": "/poem/{{ page.fileSlug }}/",
"tags": "poems" "tags": "poems"
} }