aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMitchell Riedstra <mitch@riedstra.dev>2021-07-18 16:07:09 -0400
committerMitchell Riedstra <mitch@riedstra.dev>2021-07-18 16:07:09 -0400
commit46c6d75da4768c81258d05a4965f99c0db0b3bb4 (patch)
treeaf865d30cf296c12d3e49b2abde6f2e8f69411f6
parentf2082a0d72f9359be02182883a1e1190d8b1b215 (diff)
downloadgo-website-46c6d75da4768c81258d05a4965f99c0db0b3bb4.tar.gz
go-website-46c6d75da4768c81258d05a4965f99c0db0b3bb4.tar.xz
Patch it up more
-rw-r--r--example-site/checkup.md9
-rw-r--r--example-site/index.md8
-rw-r--r--page/page.go6
3 files changed, 2 insertions, 21 deletions
diff --git a/example-site/checkup.md b/example-site/checkup.md
index f7d7a88..c8556fa 100644
--- a/example-site/checkup.md
+++ b/example-site/checkup.md
@@ -47,15 +47,6 @@ description: Showing the output of one of the internal checkup mechanisms
{{.Global.App}}
```
-#### Page Index
-
-{{range $key, $val := .Index}}
-```
-### {{$key}}:
-
-{{range $v2 := $val}}
-{{$v2.StringDetail}}{{end}}
-```
{{end}}
diff --git a/example-site/index.md b/example-site/index.md
index 42b0181..2280662 100644
--- a/example-site/index.md
+++ b/example-site/index.md
@@ -38,14 +38,10 @@ it.
{{.Global.App}}
```
-#### Page Index
+#### Page Index ( details )
-{{range $key, $val := .Index}}
```
-### {{$key}}:
-
-{{range $v2 := $val}}
-{{$v2.StringDetail}}{{end}}
+{{.EncodeYaml .Index}}
```
diff --git a/page/page.go b/page/page.go
index 5604f1c..52a441c 100644
--- a/page/page.go
+++ b/page/page.go
@@ -177,9 +177,3 @@ func (p *Page) RenderBody() (string, error) {
func (p Page) String() string {
return fmt.Sprintf("Page: %s", p.path)
}
-
-// StringDetail prints a detailed string of the page
-func (p Page) StringDetail() string {
- b, _ := json.MarshalIndent(p, "", " ")
- return fmt.Sprintf("Page: %s\n%s\n", p.path, b)
-}