-
Notifications
You must be signed in to change notification settings - Fork 4.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
9 changed files
with
115 additions
and
132 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,3 @@ | ||
--- | ||
sidebar: auto | ||
--- | ||
|
||
# Default Theme Config | ||
|
||
<Bit/> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ | |
seoTitle: Option API | Theme | ||
--- | ||
|
||
# Options | ||
# Option API | ||
|
||
## plugins | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,4 @@ | ||
--- | ||
sidebar: auto | ||
--- | ||
|
||
# 默认主题 | ||
# 默认主题配置 | ||
|
||
::: tip 提示 | ||
本页所列的选项仅对默认主题生效。如果你在使用一个自定义主题,选项可能会有不同。 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,51 +1,51 @@ | ||
# 使用主题 | ||
|
||
Using a theme is almost same as using a plugin. | ||
使用一个主题和使用一个插件几乎一致。 | ||
|
||
## Use plugins from a dependency | ||
## 使用 dependency 中的主题 | ||
|
||
Themes can be published on npm in raw Vue SFC format as `vuepress-theme-xxx`. | ||
一个插件可以在以 `vuepress-theme-xxx` 的形式发布到 npm,你可以这样使用它: | ||
|
||
``` js | ||
module.exports = { | ||
plugins: [ 'vuepress-theme-xx' ] | ||
theme: 'vuepress-theme-xx' | ||
} | ||
``` | ||
|
||
## Theme Shorthand | ||
## 主题的缩写 | ||
|
||
If you prefix the plugin with `vuepress-theme-`, you can use a shorthand to leave out that prefix: | ||
如果你的插件名以 `vuepress-theme-` 开头,你可以使用缩写来省略这个前缀: | ||
|
||
``` js | ||
module.exports = { | ||
plugins: [ 'xxx' ] | ||
theme: 'xxx' | ||
} | ||
``` | ||
|
||
Same with: | ||
和下面等价: | ||
|
||
``` js | ||
module.exports = { | ||
plugins: [ 'vuepress-theme-xxx' ] | ||
theme: 'vuepress-theme-xxx' | ||
} | ||
``` | ||
|
||
This also works with [Scoped Packages](https://docs.npmjs.com/misc/scope): | ||
这也适用于 [Scoped Packages](https://docs.npmjs.com/misc/scope): | ||
|
||
``` js | ||
module.exports = { | ||
plugins: [ '@org/vuepress-theme-xxx', '@vuepress/theme-xxx' ] | ||
theme: '@org/vuepress-theme-xxx', // 或者一个官方主题: '@vuepress/theme-xxx' | ||
} | ||
``` | ||
|
||
Shorthand: | ||
缩写: | ||
|
||
``` js | ||
module.exports = { | ||
plugins: [ '@org/xxx', '@vuepress/xxx' ] | ||
theme: '@org/xxx', // 或者一个官方主题: '@vuepress/xxx' | ||
} | ||
``` | ||
|
||
::: warning Note | ||
The plugin whose name starts with `@vuepress/theme-` is an officially maintained theme. | ||
::: warning 注意 | ||
以 `@vuepress/plugin-` 开头的插件是官方维护的插件。 | ||
::: |
Oops, something went wrong.