diff --git a/packages/vant-auto-import-resolver/README.md b/packages/vant-auto-import-resolver/README.md index bf96e0e3a..fd2ec1b70 100644 --- a/packages/vant-auto-import-resolver/README.md +++ b/packages/vant-auto-import-resolver/README.md @@ -76,6 +76,22 @@ module.exports = { }; ``` +### Rspack + +```ts +// rspack.config.js +import Components from 'unplugin-vue-components/rspack'; +import { VantResolver } from '@vant/auto-import-resolver'; + +module.exports = { + plugins: [ + Components({ + resolvers: [VantResolver()], + }), + ], +}; +``` + ### Vue CLI ```ts diff --git a/packages/vant-auto-import-resolver/README.zh-CN.md b/packages/vant-auto-import-resolver/README.zh-CN.md index 6b74ba123..46e14150b 100644 --- a/packages/vant-auto-import-resolver/README.zh-CN.md +++ b/packages/vant-auto-import-resolver/README.zh-CN.md @@ -76,6 +76,22 @@ module.exports = { }; ``` +### Rspack + +```ts +// rspack.config.js +import Components from 'unplugin-vue-components/rspack'; +import { VantResolver } from '@vant/auto-import-resolver'; + +module.exports = { + plugins: [ + Components({ + resolvers: [VantResolver()], + }), + ], +}; +``` + ### Vue CLI ```ts diff --git a/packages/vant-auto-import-resolver/package.json b/packages/vant-auto-import-resolver/package.json index c6ef9b5f2..a18e06ce5 100644 --- a/packages/vant-auto-import-resolver/package.json +++ b/packages/vant-auto-import-resolver/package.json @@ -1,7 +1,7 @@ { "name": "@vant/auto-import-resolver", "version": "1.0.0", - "description": "Vant auto import resolver base unplugin-vue-components", + "description": "Vant auto import resolver based on unplugin-vue-components", "main": "dist/index.cjs.js", "module": "dist/index.esm.mjs", "typings": "dist/index.d.ts",