From 6c2b156d020e9d144a53567d5f6418c2a4e4421e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Codru=C8=9B=20Constantin=20Gu=C8=99oi?= Date: Tue, 31 Mar 2020 23:21:52 +0100 Subject: [PATCH] Adds `.Content` to list.html partial --- CONTRIBUTORS.md | 1 + exampleSite/content/snippets/_index.md | 5 +++++ exampleSite/content/snippets/first/index.md | 9 +++++++++ exampleSite/content/snippets/second/index.md | 9 +++++++++ layouts/partials/list.html | 1 + 5 files changed, 25 insertions(+) create mode 100644 exampleSite/content/snippets/_index.md create mode 100644 exampleSite/content/snippets/first/index.md create mode 100644 exampleSite/content/snippets/second/index.md diff --git a/CONTRIBUTORS.md b/CONTRIBUTORS.md index 41918bac0..7b0b26e4b 100644 --- a/CONTRIBUTORS.md +++ b/CONTRIBUTORS.md @@ -62,3 +62,4 @@ - [Piotr Orzechowski](https://orzechowski.tech) - [Glenn Feunteun](https://github.com/gfeun) - [Santiago González](https://github.com/netrules) +- [Codruț Constantin Gușoi](https://www.sdwolfz.pro) diff --git a/exampleSite/content/snippets/_index.md b/exampleSite/content/snippets/_index.md new file mode 100644 index 000000000..5166c00c9 --- /dev/null +++ b/exampleSite/content/snippets/_index.md @@ -0,0 +1,5 @@ +--- +title: "Snippets" +--- + +This content is in `content/snippets/_index.md` diff --git a/exampleSite/content/snippets/first/index.md b/exampleSite/content/snippets/first/index.md new file mode 100644 index 000000000..0d423e5e5 --- /dev/null +++ b/exampleSite/content/snippets/first/index.md @@ -0,0 +1,9 @@ +--- +title: "First snippet" +--- + +This content is in `snippets/first/index.md` + +```sh +pwd +``` diff --git a/exampleSite/content/snippets/second/index.md b/exampleSite/content/snippets/second/index.md new file mode 100644 index 000000000..e1ca4d18d --- /dev/null +++ b/exampleSite/content/snippets/second/index.md @@ -0,0 +1,9 @@ +--- +title: "Second snippet" +--- + +This content is in `snippets/second/index.md` + +```sh +ls -la +``` diff --git a/layouts/partials/list.html b/layouts/partials/list.html index 0eaed261b..d56a9bfa9 100644 --- a/layouts/partials/list.html +++ b/layouts/partials/list.html @@ -7,6 +7,7 @@

{{- .Title -}}

+ {{ .Content }}