mirror of
https://github.com/youzan/vant.git
synced 2025-10-15 07:30:53 +00:00
docs(auto-import-resolver): add doc for importStyle option (#12382)
* docs(auto-import-resolver): add doc for importStyle option * docs: upd
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
# Vant Auto Import Resolver
|
||||
|
||||
[English](./README.md) | 简体中文
|
||||
English | [简体中文](./README.zh-CN.md)
|
||||
|
||||
`@vant/auto-import-resolver` is a resolver for [unplugin-vue-components](https://github.com/unplugin/unplugin-vue-components) that enables on-demand importing of Vant components.
|
||||
|
||||
@@ -126,3 +126,24 @@ build({
|
||||
],
|
||||
});
|
||||
```
|
||||
|
||||
## Options
|
||||
|
||||
### importStyle
|
||||
|
||||
Whether to automatically import the corresponding styles of the components.
|
||||
|
||||
- **Type:** `boolean`
|
||||
- **Default:** `true`
|
||||
- **Example:**
|
||||
|
||||
```ts
|
||||
Components({
|
||||
resolvers: [
|
||||
VantResolver({
|
||||
// Disable style import
|
||||
importStyle: false,
|
||||
}),
|
||||
],
|
||||
});
|
||||
```
|
||||
|
@@ -1,6 +1,6 @@
|
||||
# Vant Auto Import Resolver
|
||||
|
||||
English | [简体中文](./README.zh-CN.md)
|
||||
[English](./README.md) | 简体中文
|
||||
|
||||
`@vant/auto-import-resolver` 是 [unplugin-vue-components](https://github.com/unplugin/unplugin-vue-components) 的一个解析器,用于实现 Vant 按需引入。
|
||||
|
||||
@@ -126,3 +126,24 @@ build({
|
||||
],
|
||||
});
|
||||
```
|
||||
|
||||
## 选项
|
||||
|
||||
### importStyle
|
||||
|
||||
是否自动引用组件对应的样式。
|
||||
|
||||
- **Type:** `boolean`
|
||||
- **Default:** `true`
|
||||
- **Example:**
|
||||
|
||||
```ts
|
||||
Components({
|
||||
resolvers: [
|
||||
VantResolver({
|
||||
// 禁用样式引用
|
||||
importStyle: false,
|
||||
}),
|
||||
],
|
||||
});
|
||||
```
|
||||
|
Reference in New Issue
Block a user