Skip to content

Commit 5932a61

Browse files
mrmancmmistakes
authored andcommittedAug 9, 2018
Add {{ content }} to home layout (mmistakes#1775)
* Add `{{ content }}` to `home` layout Allow the author to add content which will appear above the list of recent posts. This also allows the `home` layout to be extended. Add text to index.html in tests to indicate that the content appears in the correct spot. * Add paragraph markup Since this is a HTML file, proper paragraph markup is needed.
1 parent 0b2cb1f commit 5932a61

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed
 

‎_layouts/home.html

+2
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
layout: archive
33
---
44

5+
{{ content }}
6+
57
<h3 class="archive__subtitle">{{ site.data.ui-text[site.locale].recent_posts | default: "Recent Posts" }}</h3>
68

79
{% for post in paginator.posts %}

‎test/index.html

+2
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,5 @@
22
layout: home
33
author_profile: true
44
---
5+
6+
<p>This text should appear above the recent posts.</p>

0 commit comments

Comments
 (0)
Please sign in to comment.