flatpickr-wrap is a lightweight Date wrapper for flatpickr
This project is based on
flatpickr
, which combined withnative-date-adapter
, now it contains lunar and jalali calenders.
it has th exact configs like
flatpickr
All input and output dates are in Gregorian format. Only the display format is in Jalali, etc.
<script src="./dist/flatpickr.js"></script>
<script src="./dist/l10n/fa.js"></script>
<label>
<div>Jalali Date</div>
<input placeholder="Select Date..." class=date />
</label>
var fp = flatpickr(".date", {
locale: 'fa',
altInput: true,
altFormat: "F j, Y",
dateFormat: "Y-m-d",
})