Skip to content

Commit 7ce14f1

Browse files
committed
Document Page.Markup
1 parent 612b852 commit 7ce14f1

File tree

2 files changed

+96
-0
lines changed

2 files changed

+96
-0
lines changed

content/en/functions/hugo/Context.md

+25
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
---
2+
title: hugo.Context
3+
description: # TODO
4+
categories: []
5+
keywords: []
6+
action:
7+
aliases: []
8+
related: []
9+
returnType: string
10+
signatures: [hugo.Context]
11+
---
12+
13+
<!-- TODO -->
14+
15+
## Contexts
16+
17+
<!-- TODO -->
18+
19+
###### MarkupScope
20+
21+
<!-- TODO -->
22+
23+
```go-html-template
24+
{{ hugo.Context.MarkupScope }} → xxxxxx
25+
```

content/en/methods/page/Markup.md

+71
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
---
2+
title: Markup
3+
description: # TODO
4+
categories: []
5+
keywords: []
6+
action:
7+
related: []
8+
returnType: # TODO
9+
signatures: [PAGE.Markup]
10+
---
11+
12+
<!-- TODO -->
13+
14+
<!-- JMM It is unclear to me if things like .Page.WordCount will be deprecated in favor of .Page.Markup.CountWords. Three levels (Page, Markup, Countwords) is a bit of a pain to document with the current docs theme. Several of the Markup methods required their own page.
15+
16+
So maybe make Markup a first-level method, noting that it's a method on Page. Then each method on Markup will have its own page.
17+
-->
18+
19+
## Methods
20+
21+
###### CountWords
22+
(`int`) <!-- TODO -->
23+
24+
###### CountWordsFuzzy
25+
(`int`) <!-- TODO -->
26+
27+
###### Fragments
28+
(`tableofcontents.Fragments`) <!-- TODO -->
29+
30+
###### FragmentsHTML
31+
(`template.HTML`) <!-- TODO -->
32+
33+
###### HasShortcode
34+
(`bool`) <!-- TODO -->
35+
36+
###### Len
37+
(`int`) <!-- TODO -->
38+
39+
###### Plain
40+
(`string`) <!-- TODO -->
41+
42+
###### PlainWords
43+
(`string array`) <!-- TODO -->
44+
45+
###### ReadingTime
46+
(`int`) <!-- TODO -->
47+
48+
###### Render
49+
(`any`) <!-- TODO -->
50+
51+
###### RenderShortcodes
52+
(`template.HTM`) <!-- TODO -->
53+
54+
###### RenderString
55+
(`template.HTM`) <!-- TODO -->
56+
57+
###### Summary
58+
(`template.HTML`) <!-- TODO -->
59+
60+
## Example
61+
62+
<!-- TODO -->
63+
64+
```go-html-template
65+
{{ range .Pages }}
66+
{{ with .Markup }}
67+
{{ .Countwords }}
68+
{{ .Render }}
69+
{{ end }}
70+
{{ end }}
71+
```

0 commit comments

Comments
 (0)