1.0.4 • Published 6 years ago
@neoaren/date-picker v1.0.4
Date Picker
📅 A modern and easy-to-use React date picker component
Install
Install the date picker
npm install --save @neoaren/date-pickerPeer dependencies
This component uses React >=16.8.0 and React DOM >=16.8.0 as peer dependencies.
Install them using npm
npm install --save react react-domUsage
import React from 'react';
import DatePicker from '@neoaren/date-picker';
const App = () => {
  return (
    <DatePicker id="my-datepicker" />
  );
};Component API
| Name | Type | Required | Description | 
|---|---|---|---|
| id | String | true | The unique identifier of the date picker element. | 
| defaultValue | NumberDate | false | The default value of the date picker. | 
| onChange | Function | false | This function runs when the selected date changes. The new date passed as the only parameter is an instance of Date. | 
| placeholder | String | false | The text to be displayed when no date is selected. | 
| lang | String | false | Set the language of the date picker, the default is English. Use the ISO 8601-1 format (e.g. "en") | 
License
MIT © NeoAren