GithubHelp home page GithubHelp logo

trendingtechnology / v2-datepicker Goto Github PK

View Code? Open in Web Editor NEW

This project forked from dwqs/v2-datepicker

0.0 3.0 0.0 474 KB

A simple datepicker component based Vue 2.x: https://dwqs.github.io/v2-datepicker/

JavaScript 10.63% Vue 72.41% CSS 15.27% HTML 1.69%

v2-datepicker's Introduction

npm-version license

v2-datepicker

A simple datepicker component based Vue 2.x.

Installation

Install the pkg with npm:

npm i --save v2-datepicker

or yarn

yarn add  v2-datepicker

Usage

import Vue from 'vue';
import V2Datepicker from 'v2-datepicker';

Vue.use(V2Datepicker)
// basic
<v2-datepicker v-model="val"></v2-datepicker>

//setting
<v2-datepicker v-model="val" lang="en" format="yyyy-MM-DD"></v2-datepicker>

More demo to visit here.

Available Props

The v2-datepicker component

Attribute Type Accepted Values Default Description
value Date anything accepted by new Date - default date of the date-picker
lang String cn(chinese)/en(english) cn set local language of the date-picker
format String year yyyy/YYYY, month MM, day dd yyyy/MM/dd format of the displayed value in the span box
placeholder String - 选择日期/Choosing date... placeholder text
disabled Boolean - false disabled date-picker

The v2-daterange-picker component

Attribute Type Accepted Values Default Description
value Array anything accepted by new Date - default date of the daterange-picker
lang String cn(chinese)/en(english) cn set local language of the daterange-picker
format String year yyyy/YYYY, month MM, day dd yyyy/MM/dd format of the displayed value in the span box
placeholder String - 开始时间-结束时间/Choosing date range... placeholder text
disabled Boolean - false disabled daterange-picker
range-separator String - '-' range separator
unlink-panels Boolean - false unlink two date-panels in range-picker

Event

Event Name Description Parameters
change triggers when the selected value changes component's binding value

Development

git clone git@github.com:dwqs/v2-datepicker.git

cd v2-datepicker

npm i 

npm start

LICENSE

MIT

v2-datepicker's People

Contributors

dwqs avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.