Detailed explanation of the use of region selector (V-Distpicker) component

php中世界最好的语言
Release: 2018-05-12 10:45:26
Original
6255 people have browsed it

This time I will bring you a detailed explanation of the use of the region selector (V-Distpicker) component. What are theprecautionswhen using the region selector (V-Distpicker) component. The following is a practical case, let’s take a look together. take a look.

Installation and citation are copied directly from the official website, so I won’t go into details.

1. Installation

Use npm to install:

npm install v-distpicker --save
Copy after login

Use yarn to install

yarn add v-distpicker --save
Copy after login

2. Use

Register component

Register global component

import VDistpicker from 'v-distpicker' Vue.component('v-distpicker', VDistpicker);
Copy after login

Register component

import VDistpicker from 'v-distpicker' export default { components: { VDistpicker } }
Copy after login

Simple use

Basic

Copy after login

Default value

Copy after login

Mobile terminal

Copy after login

3. The following are the key points

Get the selected value

Copy after login

Define several methods in the parent component where you reference v-distpicker to get the selected value.