Skip to content

Commit bba22b8

Browse files
committed
archetypes: modularize initially empty home page default matcornic#300
1 parent 897e004 commit bba22b8

File tree

2 files changed

+20
-21
lines changed

2 files changed

+20
-21
lines changed

layouts/partials/_index.html

Lines changed: 5 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,9 @@
11
{{- partial "header.html" . }}
2-
{{- if .Site.Home.Content }}
3-
{{- if eq (.Scratch.Get "relearnOutputFormat") "PRINT" }}
4-
{{- partial "body.print.html" .Site.Home }}
5-
{{- else }}
6-
{{- partial "body.html" .Site.Home }}
7-
{{- end }}
2+
{{- if not .Site.Home.Content }}
3+
{{- partial "initial.html" .Site.Home }}
4+
{{- else if eq (.Scratch.Get "relearnOutputFormat") "PRINT" }}
5+
{{- partial "body.print.html" .Site.Home }}
86
{{- else }}
9-
<article>
10-
11-
<h1>Customize your own home page</h1>
12-
<p>
13-
The site is working. Don't forget to customize this page with your own. You typically have 3 choices :
14-
</p>
15-
<ul>
16-
<li><b>1.</b> Create an _index.md document in <b>content</b> folder and fill it with Markdown content</li>
17-
<li><b>2.</b> Create an <b>index.html</b> file in the <b>static</b> folder and fill the file with HTML content</li>
18-
<li><b>3.</b> Configure your server to automatically redirect home page to one your documentation page</li>
19-
</ul>
20-
21-
<footer class="footline">
22-
</footer>
23-
</article>
7+
{{- partial "body.html" .Site.Home }}
248
{{- end }}
259
{{- partial "footer.html" . }}

layouts/partials/initial.html

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
<article>
2+
3+
<h1>Customize your own home page</h1>
4+
<p>
5+
The site is working. Don't forget to customize this page with your own. You typically have 3 choices :
6+
</p>
7+
<ul>
8+
<li><b>1.</b> Create an _index.md document in <b>content</b> folder and fill it with Markdown content</li>
9+
<li><b>2.</b> Create an <b>index.html</b> file in the <b>static</b> folder and fill the file with HTML content</li>
10+
<li><b>3.</b> Configure your server to automatically redirect home page to one your documentation page</li>
11+
</ul>
12+
13+
<footer class="footline">
14+
</footer>
15+
</article>

0 commit comments

Comments
 (0)