#157, Make docs template default for all pages

This commit is contained in:
Alex Shpak 2020-02-29 21:24:00 +01:00
parent 6ecc94ed2b
commit 4ee099e8cf
6 changed files with 6 additions and 47 deletions

View File

@ -71,9 +71,11 @@
{{ end }}
{{ define "main" }}
{{ .Content }}
<article class="markdown">
{{- .Content -}}
</article>
{{ end }}
{{ define "toc" }}
{{ .TableOfContents }}
{{ partial "docs/toc" . }}
{{ end }}

View File

@ -0,0 +1 @@
{{ define "dummy" }}{{ end }}

View File

@ -0,0 +1 @@
{{ define "dummy" }}{{ end }}

View File

@ -1,9 +0,0 @@
{{ define "main" }}
<article class="markdown">
{{- .Content -}}
</article>
{{ end }}
{{ define "toc" }}
{{ partial "docs/toc" . }}
{{ end }}

View File

@ -1,9 +0,0 @@
{{ define "main" }}
<article class="markdown">
{{- .Content -}}
</article>
{{ end }}
{{ define "toc" }}
{{ partial "docs/toc" . }}
{{ end }}

View File

@ -1,27 +0,0 @@
<!DOCTYPE html>
<html lang="{{ .Site.Language.Lang }}">
<head>
{{ partial "docs/html-head" . }}
{{ partial "docs/inject/head" . }}
</head>
{{ $content := `
# Hugo Book Theme
This is a placeholder for home page.
You can override this page in:
- &#96;/content/_index.md&#96;
- &#96;/layouts/home.html&#96;
` }}
<body>
<main class="flex justify-center">
<div class="book-home markdown">
{{ replace $content "&#96;" "`" | markdownify }}
</div>
</main>
{{ partial "docs/inject/body" . }}
</body>
</html>