holy-time
v6.0.1
Published
Utility functions
Downloads
1,089
Readme
Holy Time
Yet another (type-safe) date time library.
Installation
$ npm install holy-time
OR
$ yarn add holy-time
Resources
Examples
import HolyTime from 'holy-time'
HolyTime
.in(4, 'days')
.add(2, 'weeks')
.subtract(4, 'minutes')
.isWeekend()
HolyTime
.between(
HolyTime.add(HolyTime.startOf('day'), 2, 'hours'),
HolyTime.now()
)
.in('hours')
HolyTime.max(1666224000000, HolyTime.next('year'))
new HolyTime('2022-10-20')
.isAfter(
HolyTime.subtract(
HolyTime.in(4, 'days'),
8, 'weeks'
)
)
HolyTime
.duration(2, 'hours')
.add(30, 'minutes')
.in('seconds')