Skip to content
This repository has been archived by the owner on Mar 30, 2022. It is now read-only.

strong-roots-capital/enumerate-sessions-between

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

37 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

enumerate-sessions-between Build status npm version codecov

Enumerate sessions between two dates (inclusive)

Install

npm install @strong-roots-capital/enumerate-sessions-between

Use

import enumerateSessionsBetween from '@strong-roots-capital/enumerate-sessions-between'
import moment from 'moment'

const start = moment.utc().startOf('day').toDate()
const end = moment.utc(start).add(1, 'day').toDate()
console.log(enumerateSessionsBetween('1D', start, end))
//=>[ 2019-04-15T00:00:00.000Z, 2019-04-16T00:00:00.000Z ]

Related