🎉New version released! 🎉
npm i air-datepicker
import AirDatepicker from 'air-datepicker' import 'air-datepicker/air-datepicker.css' new AirDatepicker('#el' [, options]);
Demo and docs
- new feature that allow you to add custom attributes via
onRenderCell#502, read docs
- fixed selecting cell when using custom html with
- added Swedish locale, thanks to naton #207
- fixed error when trying to call
viewparameter on hidden calendar, #476
- fixed styles issue with time sliders, #489
- fixed English docs description, #490
- fixed typings for
Version 3.0.0 highlights
It is been a while since the last release, a lot of work has been done, and I'm glad to finally present a new version of Air Datepicker.
The main goal was to remove jQuery dependency, and I'm happy to announce that Air Datepicker is no longer need any dependency, hurray!
Now it's written in ES6, uses native css variables for easy customization, and it's all built with webpack.
Soooo, here is the full list of changes:
- no more jQuery
- improve rendering process - remove redundant cell render when selecting date, which gave a large speed boost compared to the old version
- date format tokens now use Unicode Technical Standard
- TypeScript support
selectedDatesoption, to be able to select dates from the start
- added a possibility to create custom buttons
- now one could change selected range by dragging dates
containeroption which allows you to place datepicker in a custom element
navTitlescan receive a function and could render dynamically
dateFormatnow can receive a function
onRenderCellcallbacks are now receive a single object as an argument instead of multiple parameters
selectDatenow receives second parameter with options
onChangeDecadesare replaced with single option
- localization now must be provided as an object instead of string as it was before
- To run project run
npm i, then
npm run dev:serve.
- If you want to report a bug, please provide steps and code to reproduce it or create a live example. You could use this template for creating sandbox
- If you have a question please ask it on StackOverflow with tag
- If you have a proposal or PR please submit it to the main branch - please follow code style according to .eslint configuration. Also make sure that your effort is aligned with project roadmap - my goal is to keep datepicker clean and lightweight (under 15kb) without overcomplications or narrowly focused features
Air Datepicker is MIT licensed.