You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/default-theme-config/README.md
+8-8
Original file line number
Diff line number
Diff line change
@@ -10,7 +10,7 @@ All options listed on this page apply to the default theme only. If you are usin
10
10
11
11
## Homepage
12
12
13
-
The default theme provides a homepage layout (which is used on [the homepage of this very website](/)). To use it, specify `home: true` plus some other metadata in your root `README.md`'s YAML front matter. This is the actual data used on this site:
13
+
The default theme provides a homepage layout (which is used on [the homepage of this very website](/)). To use it, specify `home: true` plus some other metadata in your root `README.md`'s [YAML front matter](../guide/markdown.html#yaml-front-matter). This is the actual data used on this site:
Any additional content after the front matter will be parsed as normal markdown and rendered after the features section.
32
+
Any additional content after the `YAML front matter` will be parsed as normal markdown and rendered after the features section.
33
33
34
34
If you want to use a completely custom homepage layout, you can also use a [Custom Layout](#custom-layout-for-specific-pages).
35
35
@@ -67,13 +67,13 @@ module.exports = {
67
67
}
68
68
```
69
69
70
-
You can omit the `.md` extension, and paths ending with `/` are inferred as `*/README.md`. The text for the link is automatically inferred (either from the first header in the page or explicit title in YAML frontmatter). If you wish to explicitly specify the link text, use an Array in form of `[link, text]`.
70
+
You can omit the `.md` extension, and paths ending with `/` are inferred as `*/README.md`. The text for the link is automatically inferred (either from the first header in the page or explicit title in `YAML front matter`). If you wish to explicitly specify the link text, use an Array in form of `[link, text]`.
71
71
72
72
### Nested Header Links
73
73
74
74
The sidebar automatically displays links for headers in the current active page, nested under the link for the page itself. You can customize this behavior using `themeConfig.sidebarDepth`. The default depth is `1`, which extracts the `h2` headers. Setting it to `0` disables the header links, and the max value is `2` which extracts both `h2` and `h3` headers.
75
75
76
-
A page can also override this value in using YAML frontmatter:
76
+
A page can also override this value in using `YAML front matter`:
77
77
78
78
```md
79
79
---
@@ -151,7 +151,7 @@ module.exports = {
151
151
152
152
### Auto Sidebar for Single Pages
153
153
154
-
If you wish to automatically generate a sidebar that contains only the header links for the current page, you can use YAML front matter on that page:
154
+
If you wish to automatically generate a sidebar that contains only the header links for the current page, you can use `YAML front matter` on that page:
155
155
156
156
```yaml
157
157
---
@@ -161,7 +161,7 @@ sidebar: auto
161
161
162
162
### Disabling the Sidebar
163
163
164
-
You can disable the sidebar on a specific page with YAML front matter:
164
+
You can disable the sidebar on a specific page with `YAML front matter`:
165
165
166
166
```yaml
167
167
---
@@ -171,7 +171,7 @@ sidebar: false
171
171
172
172
## Prev / Next Links
173
173
174
-
Prev and next links are automatically inferred based on the sidebar order of the active page. You can also explicitly overwrite or disable them using YAML front matter:
174
+
Prev and next links are automatically inferred based on the sidebar order of the active page. You can also explicitly overwrite or disable them using `YAML front matter`:
175
175
176
176
```yaml
177
177
---
@@ -216,7 +216,7 @@ $codeBgColor = #282c34
216
216
217
217
## Custom Layout for Specific Pages
218
218
219
-
By default the content of each `*.md` file is rendered in a `<div class="page">` container, along with the sidebar, auto-generated edit links and prev/next links. If you wish to use a completely custom component in place of the page (while only keeping the navbar), you can again specify the component to use using YAML front matter:
219
+
By default the content of each `*.md` file is rendered in a `<div class="page">` container, along with the sidebar, auto-generated edit links and prev/next links. If you wish to use a completely custom component in place of the page (while only keeping the navbar), you can again specify the component to use using `YAML front matter`:
Copy file name to clipboardExpand all lines: docs/guide/custom-themes.md
+1-1
Original file line number
Diff line number
Diff line change
@@ -37,7 +37,7 @@ This is the value of `$site` of this very website:
37
37
}
38
38
```
39
39
40
-
`title`, `description` and `base` are copied from respective fields in `.vuepress/config.js`. `pages` contains an array of metadata objects for each page, including its path, page title (explicitly specified in YAML frontmatter or inferred from the first header on the page), and any YAML frontmatter data in that file.
40
+
`title`, `description` and `base` are copied from respective fields in `.vuepress/config.js`. `pages` contains an array of metadata objects for each page, including its path, page title (explicitly specified in [YAML front matter](./markdown.html#yaml-front-matter)or inferred from the first header on the page), and any YAML front matter data in that file.
41
41
42
42
This is the `$page` object for this page you are looking at:
0 commit comments