rci-datepicker
v1.0.5
Published
A simple react input that displays a calendar to pick a date format value.
Downloads
6
Maintainers
Readme
rci-datepicker
Minimal requirements
This library requires node.js >= 13.2.0 and React >= 16.8.0
Get started
Install the component via npm.
npm install rci-datepicker
Import the component in your project
import DatePicker from "rci-date-picker";
Use it like an input by using onChange() on it.
function Component() {
const [selectedDate, setSelectedDate] = useState(null);
return (
<div>
<h1>Date Picker Example</h1>
<DatePicker onChange={(e) => setSelectedDate(e.target.value)} />
<p>Selected Date: {selectedDate}</p>
</div>
);
}