defstudio / supercharged-carbon
A supercharged Carbon decorator
v3.0.1
2026-01-30 14:42 UTC
Requires
- php: ^8.2
- illuminate/support: ^11.0|^12.0
- nesbot/carbon: ^3.0
README
Carbon helper function
carbon('2018-04-18') returns a carbon instance
- addWorkdays($count): self
- isHoliday()
- isWorkday()
italians holidays
- isLiberationDay()
- isRepublicDay()
- isImmaculateConceptionFeast()
- isAssumptionOfMaryFeast()
- isEpiphany()
- isDayBeforeChristmas()
- isChristmas()
- isSaintStephenDay()
- isSaintSylvesterDay()
- isWorkersDay()
- isEasterDay()
- isEasterMonday()
Upgrading
v1.x → v2.x
->isHoliday() does not answer true for Saturdays and Sundays, so, to obtain the same result as in v1.x this:
$date->isHoliday()
should be changed to:
!$date->isWorkday()
or
$date->isHoliday() || $date->isWeekend()