Skip to content

docs(zh): correction of some format problems #6036

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Nov 9, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions docs/zh/dev-guide/plugin-dev.md
Original file line number Diff line number Diff line change
Expand Up @@ -293,15 +293,15 @@ module.exports.hooks = (api) => {
}
```

### Service 插件
## Service 插件

Service 插件可以修改 webpack 配置,创建新的 vue-cli service 命令或者修改已经存在的命令(如 `serve` 和 `build`)。

Service 插件在 Service 实例被创建后自动加载 - 例如,每次 `vue-cli-service` 命令在项目中被调用的时候。它位于 CLI 插件根目录的 `index.js` 文件。

一个 service 插件应该导出一个函数,这个函数接受两个参数:

- 一个 [PluginAPI][plugin-api.md] 实例
- 一个 [PluginAPI](plugin-api.md) 实例

- 一个包含 `vue.config.js` 内指定的项目本地选项的对象,或者在 `package.json` 内的 `vue` 字段。

Expand Down