1.1.0 • Published 3 years ago

@monsterbilligt/date-fns-holidays v1.1.0

Weekly downloads
-
License
ISC
Repository
-
Last release
3 years ago

date-fns-holidays

Provides replacement functions for date-fns@2.x that take into account Danish holidays.

Installation

npm i @monsterbilligt/date-fns-holidays

Usage

import { addBusinessDays, differenceInBusinessDays } from '@monsterbilligt/date-fns-holidays'

const newDate = addBusinessDays(new Date(), 10) // Adds 10 business days to today

const diff = differenceInBusinessDays(newDate, new Date()) // Should be 10