react-basic-datepicker
v1.1.3
Published
A barebones, no-frills datepicker for React
Downloads
42
Maintainers
Readme
React Basic Datepicker
A barebones, super-simple datepicker built with React. This was built to be as simple and small as I could make it, if you want something with a few more features then check out React Datepicker.
Usage
Render the datepicker and supply any of the props listed below.
ReactDOM.render(<Datepicker dateFormat="DD/MM/YYYY" />, document.getElementById('react-root'));
There are basic styles defined in the demo directory which can be copied into your project.
Props
You can customise the datepicker by supplying the follow props.
dateFormat
e.g. DD-MM-YYYYstartDate
e.g.new Date()
minDate
e.g.new Date(2016, 11)
prevButtonLabel
e.g. 'Previous Month'nextButtonLabel
e.g. 'Next Month'handleDateChange
e.g. set state or do whatever with the date...datepickerName
e.g.my-date-picker
datepickerId
e.g.my-date-picker
datepickerClassName
e.g.my-date-picker