Fix code example

This commit is contained in:
Bjørn Erik Pedersen 2017-09-30 11:40:52 +02:00 committed by GitHub
parent 05aaee8cec
commit f78cf64909

View File

@ -143,8 +143,7 @@ This example HTML code block tells Hugo users the following:
2. This snippet is complete enough to be downloaded and implemented in a Hugo project, as demonstrated by `download="single.html"`. 2. This snippet is complete enough to be downloaded and implemented in a Hugo project, as demonstrated by `download="single.html"`.
``` ```
{{%/* code file="layouts/_default/single.html" download="single.html" */%}} {{</* code file="layouts/_default/single.html" download="single.html" */>}}
```
{{ define "main" }} {{ define "main" }}
<main> <main>
<article> <article>
@ -162,14 +161,14 @@ This example HTML code block tells Hugo users the following:
</article> </article>
</main> </main>
{{ end }} {{ end }}
``` {{</* /code */>}}
{{%/* /code */%}}
``` ```
##### Example 'code' Display ##### Example 'code' Display
The output of this example will render to the Hugo docs as follows: The output of this example will render to the Hugo docs as follows:
```html
{{< code file="layouts/_default/single.html" download="single.html" >}} {{< code file="layouts/_default/single.html" download="single.html" >}}
{{ define "main" }} {{ define "main" }}
<main> <main>
@ -189,6 +188,7 @@ The output of this example will render to the Hugo docs as follows:
</main> </main>
{{ end }} {{ end }}
{{< /code >}} {{< /code >}}
```
<!-- #### Output Code Block <!-- #### Output Code Block