vue-zone
Vue-based zone selection component
Screenshots
Install
Get source from npm or yarn.
# Npm$ npm install vue-zone --save# Yarn (recommend)$ yarn add vue-zone
Support UMD library and individual CSS file.
./lib/├── vue-zone.js└── vue-zone.css./src/├── /components/│ ├── area.vue│ └── area-country.vue│ └── area-zone.vue│ └── area-province.vue└── index.js
// For ES6 module // Import from src code for debugging or self building;
And import CSS file:
;
Usage
<template> <div id="app"> <zone @change="handleChange"> </zone> </div></template>
name: 'app' { return week: } methods: { thischoose = choose }
API
Events
Event Name | Description | Return Value |
---|---|---|
change | Callback when clicking checkbox. | [] |
Build Setup
# install dependenciesnpm install / yarn install# serve with hot reload at localhost:8080npm run demo:dev# build for demo with minificationnpm run demo:build# build for gh-pages with minificationnpm run demo:prepublish# build for production with minificationnpm run build
TODO
- Remove the dependency on element-ui
License
MIT