Releases: geoffreyrose/us-holidays
Releases · geoffreyrose/us-holidays
Reset the Index when using setHolidays()
2.2.1 Returning holiday array with array_values() to reset the index (#7)
New Business Day Functions and Set Which Holidays To Use
- Code refactor
- Adds several business day functions
- Adds ability to set which holidays to use
- Adds ability to override which holidays are "Bank Holidays"
- Adds PHP 8 Support
New Functions: getNextHolidays() and getPrevHolidays()
Added:
- getNextHolidays()
- getPrevHolidays()
- getNextHolidayName()
- getNextHolidayDays()
- getPrevHolidayName()
- getPrevHolidayDays()
https://geoffreyrose.github.io/us-holidays/#getNextHolidays
Fixed a bug with isBankHoliday when the current day is on a weekend
Fixed bug with showing today is a holiday
fixed a bug when today is a holiday. It wouldn't show today is a holiday unless it was exactly midnight when using getHolidaysInDays
or getHolidaysInYears
Anonymous Function With addHoliday
Fixed a bug when using an anonymous function for the date with addHoliday
v2 Is Released
- Get holiday functions now return an object with the holiday's: name, date, bank_holiday and days_away; instead of only the date
- Can now add your own holidays to the list of holidays with the addHoliday function
- Added new functions: getHolidaysByYear, getHolidaysInDays, and getHolidaysInYears
Full Documentation
Add Support for 9 Additional Holidays
New Holidays Supported
- Ash Wednesday
- Easter
- Good Friday
- Hanukkah
- Orthodox Easter
- Palm Sunday
- Passover
- Rosh Hashanah
- Yom Kippur
Total holidays supported is now at 41