Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/EmielH/tale-hugo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEmiel Hollander <EmielH@users.noreply.github.com>2018-10-21 22:08:17 +0300
committerEmiel Hollander <EmielH@users.noreply.github.com>2018-10-21 22:08:17 +0300
commite50ae3922946c7facf3597a4348aa7fdda655b4f (patch)
treeb32d6f19c6762ffd97f91d9632d4439e9a1b63d3
parentffc436900bc174126845ad5fe632d151e16a0ff6 (diff)
Add partial for introduction on index page
-rw-r--r--README.md4
-rw-r--r--layouts/index.html2
-rw-r--r--layouts/partials/index/introduction.html5
3 files changed, 11 insertions, 0 deletions
diff --git a/README.md b/README.md
index 151546b..ac7744a 100644
--- a/README.md
+++ b/README.md
@@ -81,6 +81,10 @@ The theme contains placeholder partials to make the theme more flexible and easi
These are included in the template for a single post, at the top of the post (below the title) and at the bottom of the post, respectively. These can be used, for example, to include additional information about the post author or for related posts. Create a file `/layouts/partials/single/header.html` or `footer.html` on your own site to have it included.
+- `index/introduction.html`
+
+This partial is included at the top of the list of posts on the index page, allowing you to add an introduction to your site.
+
## Acknowledgments
Thanks
diff --git a/layouts/index.html b/layouts/index.html
index 5918367..8b4b147 100644
--- a/layouts/index.html
+++ b/layouts/index.html
@@ -1,6 +1,8 @@
{{ define "main" }}
<main>
+ {{ partial "index/introduction.html" . }}
+
<div class="catalogue">
{{ range (.Paginate .Pages).Pages }}
{{ .Render "summary" }}
diff --git a/layouts/partials/index/introduction.html b/layouts/partials/index/introduction.html
new file mode 100644
index 0000000..5b636b8
--- /dev/null
+++ b/layouts/partials/index/introduction.html
@@ -0,0 +1,5 @@
+<!--
+This is a placeholder partial for the introduction. Create a file called
+layouts/partials/index/introduction.html in your own site to overwrite this
+placeholder.
+-->