mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-05 19:41:42 +08:00
docs: add area data update tips (#10400)
This commit is contained in:
parent
6162b9f927
commit
5f67b9ee42
@ -1,6 +1,6 @@
|
||||
# Vant Area Data
|
||||
|
||||
省市区数据,适用于 Vant Area 组件。
|
||||
中国省市区数据,适用于 Vant Area 组件。
|
||||
|
||||
## 安装
|
||||
|
||||
@ -20,3 +20,7 @@ pnpm add @vant/area-data
|
||||
```ts
|
||||
import { areaList } from '@vant/area-data';
|
||||
```
|
||||
|
||||
## 数据更新
|
||||
|
||||
中国的行政区划每年都会有变动,如果发现省市区数据未及时更新,欢迎提 Pull Request 帮助我们更新。
|
||||
|
@ -52,7 +52,7 @@ export default {
|
||||
|
||||
### @vant/area-data
|
||||
|
||||
Vant officially provides a default area data, which can be imported through [@vant/area-data](https://github.com/youzan/vant/tree/dev/packages/vant-area-data):
|
||||
Vant officially provides a default China area data, which can be imported through [@vant/area-data](https://github.com/youzan/vant/tree/dev/packages/vant-area-data):
|
||||
|
||||
```bash
|
||||
# with npm
|
||||
|
@ -54,7 +54,7 @@ const areaList = {
|
||||
|
||||
### @vant/area-data
|
||||
|
||||
Vant 官方提供了一份默认的省市区数据,可以通过 [@vant/area-data](https://github.com/youzan/vant/tree/dev/packages/vant-area-data) 引入:
|
||||
Vant 官方提供了一份默认的中国省市区数据,可以通过 [@vant/area-data](https://github.com/youzan/vant/tree/dev/packages/vant-area-data) 引入:
|
||||
|
||||
```bash
|
||||
# 通过 npm
|
||||
@ -77,6 +77,8 @@ export default {
|
||||
};
|
||||
```
|
||||
|
||||
> Tips: 中国的行政区划每年都会有变动,如果发现省市区数据未及时更新,欢迎提 Pull Request 帮助我们更新。
|
||||
|
||||
### 选中省市区
|
||||
|
||||
如果想选中某个省市区,需要传入一个 `value` 属性,绑定对应的地区码。
|
||||
|
Loading…
x
Reference in New Issue
Block a user