# t-city-picker

> china city picker (vue)

Latest version **1.0.2** (published 2018-04-06) · ISC license · 0 weekly downloads

## Install

```sh
npm install t-city-picker
pnpm add t-city-picker
yarn add t-city-picker
bun add t-city-picker
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.2 |
| Published | 2018-04-06 |
| First published | 2018-04-06 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 176.6 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | cxgsy |
| Maintainers | cxgsy |
| Keywords | vue, city-picker, componet, moblie |

## Links

- npm: https://www.npmjs.com/package/t-city-picker
- Repository: https://github.com/rwjCxgsy
- npm.io page: https://npm.io/package/t-city-picker

## Recent versions

- 1.0.2 (latest) — 2018-04-06

## README

一个vue手机三级联动城市插件
====
# t-city-picker

## demo演示

[demo] (http://121.196.208.78/tcitypicker/index.html)

## 安装

```JS
npm install t-city-picker -d
```

## 使用

``` js
import tCityPicker from 't-city-picker'
// require
var tCityPicker = require('t-city-picker')

Vue.use(tCityPicker)

// 或者直接使用script导入
<script src="./dist/t-city-picker.js"></script>

// 作为组件的方式使用

<t-city-picker :color="'#d33'" ref="tCityPicker" v-model="value"></t-city-picker>
```

### 配置

``` html
  <t-city-picker
    :color="#d33"
    ref="tCityPicker"
    v-model="value"
    >
   ...可以自己自定义名字
  </t-city-picker>
```

```javascript
methods:{
  data () {
    return {
      value: '四川省南充市南部县'
      // 四川省南充市南部县  支持4种格式
      // 四川省-南充市-南部县 
      // 四川省-南充市-南部县
      // 四川省 南充市 南部县
    }
  }
  open() { // 打开选择器
    this.$refs.tCityPicker.open()
  }
}
```

### Props

|    名字    |    描述   |   参数类型   |默认值| 其他说明 |
| -----------------  | ---------------- | :--------: | :----------: | :----------: |
| color       | 选择时的颜色 |String| #81b2f9
| v-model       | 双向绑定地址 |String| 北京市北京市东城区 |

---
_Source: https://npm.io/package/t-city-picker · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
