npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

v-regions

v1.1.1

Published

2021最新省市区县三级联动(数据源:腾讯位置服务(行政区划)API) 基于Vue2.x、ElementUI2.x

Downloads

5

Readme

Vue2.x ElementUI2.x 2021最新省市区县三级联动

最近更新(2021年6月19日)

数据源已更新为腾讯位置服务(行政区划)API,增加了香港、澳门、台湾相关数据~

案例和文档(Examples and Documentation)

v-regions案例和文档

安装

未安装ElementUI

npm install -S element-ui v-regions

已安装ElementUI

npm install -S v-regions

引入VeRegions

你可以引入整个VeRegions,或是根据需要仅引入部分组件。我们先介绍如何引入完整的VeRegions。

完整引入

在main.js中写入一下内容

import ElementUI from 'element-ui';
import 'element-ui/lib/theme-chalk/index.css';
import VeRegions from "v-regions";

Vue.use(ElementUI);

Vue.use(VeRegions);

以上代码便完成了VeRegions的引入。

按需引入

import ElementUI from 'element-ui';
import 'element-ui/lib/theme-chalk/index.css';
import { VeProvince, VeProvinceCity, VeProvinceCityArea, VeCascader } from "v-regions";

Vue.use(ElementUI);

Vue.use(VeProvince);
Vue.use(VeProvinceCity);
Vue.use(VeProvinceCityArea);
Vue.use(VeCascader);

省、省市、省市区(县)、级联省市区(县)三级联动

组件均支持属性以下属性

禁用 | 组件 | 参数 | 类型 | 可选值 | 默认值 | |:--- | :---: | :---: | :---: | :---: | |ve-province| Boolean |disabled|true/false|false| |ve-province-city| Boolean |disabled|true/false|false| |ve-province-city-area| Boolean |disabled|true/false|false|

是否显示"全部" | 组件 | 参数 | 类型 | 可选值 | 默认值 | |:--- | :---: | :---: | :---: | :---: | |ve-province| Boolean |is-all|true/false|false| |ve-province-city| Boolean |is-all|true/false|false| |ve-province-city-area| Boolean |is-all|true/false|false|

可自定义"全部" | 组件 | 参数 | 类型 | 可选值 | 默认值 | |:--- | :---: | :---: | :---: | :---: | |ve-province| String |all-text|--|全部| |ve-province-city| String |all-text|--|全部| |ve-province-city-area| String |all-text|--|全部|

尺寸 | 组件 | 参数 | 类型 | 可选值 | 默认值 | |:--- | :---: | :---: | :---: | :---: | |ve-province| String |size|medium/small/mini|--| |ve-province-city| String |size|medium/small/mini|--| |ve-province-city-area| String |size|medium/small/mini|--|

<template>
  <div id="app">
    <ve-province v-model="province"></ve-province>
    <br />
    <ve-province-city v-model="provinceCity"></ve-province-city>
    <br />
    <ve-province-city-area v-model="sregion"></ve-province-city-area>
    <br />
    <ve-cascader v-model="cregion"></ve-cascader>
    <br />
  </div>
</template>

<script>
export default {
  data () {
    return {
      province: {},
      provinceCity: {},
      sregion: {},
      cregion: {},
    }
  }
}
</script>

数据来源

告花子/2021最新省市区.