npm.io
1.2.1 • Published 4 years ago

datepicker-react-by-badbmo

Licence
ISC
Version
1.2.1
Deps
0
Size
16 kB
Vulns
0
Weekly
0

A date picker component for your react project

A simple react datepicker to add to your react projects.

Installation

Install the component

  • Use yarn or npm to install the component.
#yarn
yarn add datepicker-react-by-badbmo
#npm
npm i datepicker-react-by-badbmo
Add it to your project
  • Import the date picker in your React app:
import DatePicker from "datepicker-react-by-badbmo"
How to use it ?
Param Type Name Use Example
1 string idInput to set the id of input and for of label "date-of-birth"
2 string nameOfLabel to set the name displayed in label "Date of Birth"
3 function getSelectedDate function to get the selected date value in a Date format const exampleOfFunction = (date) => {return console.log(date);};
Need an example ?

Go to the github to see a live version of this component.

Happy coding ! :)

Keywords