Skip to content

Commit 79ea891

Browse files
authored
doc: vite-plugin-components has been renamed to unplugin-vue-components (#5043)
1 parent 46b2162 commit 79ea891

File tree

4 files changed

+16
-10
lines changed

4 files changed

+16
-10
lines changed

site/src/vueDocs/getting-started.en-US.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ And this plugin can load styles too, read [usage](https://github.com/ant-design/
105105

106106
> FYI, babel-plugin-import's `style` option will importing some global reset styles, don't use it if you don't need those styles. You can import styles manually via `import 'ant-design-vue/dist/antd.css'` and override the global reset styles.
107107
108-
If you use Vite, you can use [vite-plugin-components](https://github.com/antfu/vite-plugin-components) to load on demand.
108+
If you use Vite, you can use [unplugin-vue-components](https://github.com/antfu/unplugin-vue-components) to load on demand.
109109

110110
## Customization
111111

site/src/vueDocs/getting-started.zh-CN.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ import { Button } from 'ant-design-vue';
105105

106106
> 注意,babel-plugin-import 的 `style` 属性除了引入对应组件的样式,也会引入一些必要的全局样式。如果你不需要它们,建议不要使用此属性。你可以 `import 'ant-design-vue/dist/antd.css` 手动引入,并覆盖全局样式。
107107
108-
如果你使用的 Vite,你可以使用 [vite-plugin-components](https://github.com/antfu/vite-plugin-components) 来进行按需加载
108+
如果你使用的 Vite,你可以使用 [unplugin-vue-components](https://github.com/antfu/unplugin-vue-components) 来进行按需加载
109109

110110
## 配置主题和字体
111111

site/src/vueDocs/introduce.en-US.md

+7-4
Original file line numberDiff line numberDiff line change
@@ -115,13 +115,16 @@ import 'ant-design-vue/dist/antd.css'; // or 'ant-design-vue/dist/antd.less'
115115

116116
```js
117117
// vite.config.js
118-
import ViteComponents, { AntDesignVueResolver } from 'vite-plugin-components';
119-
118+
import Components from 'unplugin-vue-components/vite'
119+
import { AntDesignVueResolver } from 'unplugin-vue-components/resolvers'
120+
120121
export default {
121122
plugins: [
122123
/* ... */
123-
ViteComponents({
124-
customComponentResolvers: [AntDesignVueResolver()],
124+
Components({
125+
resolvers: [
126+
AntDesignVueResolver(),
127+
],
125128
}),
126129
],
127130
};

site/src/vueDocs/introduce.zh-CN.md

+7-4
Original file line numberDiff line numberDiff line change
@@ -117,13 +117,16 @@ import 'ant-design-vue/dist/antd.css'; // or 'ant-design-vue/dist/antd.less'
117117

118118
```js
119119
// vite.config.js
120-
import ViteComponents, { AntDesignVueResolver } from 'vite-plugin-components';
121-
120+
import Components from 'unplugin-vue-components/vite'
121+
import { AntDesignVueResolver } from 'unplugin-vue-components/resolvers'
122+
122123
export default {
123124
plugins: [
124125
/* ... */
125-
ViteComponents({
126-
customComponentResolvers: [AntDesignVueResolver()],
126+
Components({
127+
resolvers: [
128+
AntDesignVueResolver(),
129+
],
127130
}),
128131
],
129132
};

0 commit comments

Comments
 (0)