@goodies/is-same-day
v1.0.1
Published
A simple package to check whether two dates represent the same day.
Downloads
10
Readme
is-same-day
System Requirements
Installation
npm i @goodies/is-same-day
yarn add @goodies/is-same-day
Usage
import isSameDay from '@goodies/is-same-day'
const today = new Date()
const yesterday = new Date()
yesterday.setDate(today.getDate() - 1)
console.log(await isSameDay(today, today)) // true
console.log(await isSameDay(today, yesterday)) // false