Skip to content
This repository has been archived by the owner on Jan 7, 2019. It is now read-only.

kraf/react-datetimepicker

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

34 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

About

Simple datetimepicker for use with React.js. The only dependencies are moment and React. The styling is minimal and you will most likely have to customize it.

Changes

  • 2.0.0
    • Breaking: switched to managed values

Usage

npm install react-datetimepicker

var DateTimePicker = require("react-datetimepicker");

API

Properties with defaults (all optional)

weekStart=1 // 0 -> Sun, 1 -> Mon, 2 -> Tue, 3 -> Wed, 4 -> Thu, 5 -> Fri, 6 -> Sat
time=true // show/hide time picker part
inputMode=true // render input or inline datepicker
dateFormat='YYYY-MM-DD' // used for input when time is set to false
dateValidator=undefined // bool function(date) - return false to disable selection of particular date
dateTimeFormat='YYYY-MM-DD HH:mm' // used for input when time is set to true
value=(new Date()) // 
onChange=undefined // Gets invoked when selection changes

About

Basic React datetimepicker component

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages