date-range-handler
v2.0.0
Published
A simple and efficient JavaScript package to handle date ranges and financial years, including support for quarters, months, and custom date ranges. It provides utility functions to generate start and end dates based on different user inputs.
Readme
Date Range Handler
A simple and efficient JavaScript package to handle date ranges and financial years, including support for quarters, months, and custom date ranges. It provides utility functions to generate start and end dates based on different user inputs.
Features
- Get default start and end dates for the current financial year (FY).
- Handle custom start and end dates.
- Support for quarterly ranges (
Q1,Q2,Q3,Q4). - Handle ranges such as months (
1M,2M,1Y, etc.). - Support "All" range with no date requirement.
- Expand year-only dates to full date formats.
Installation
To install the package, run the following command in your project directory:
npm install date-range-handler