Aller au contenu principal

@w5s/time

W5S Time manipulation (@w5s/time)

NPM Version License

Installation

npm install @w5s/time

Usage

import { Time, TimeDuration } from '@w5s/time';
import { Task } from '@w5s/task';

export function nowPlusTwoMinutes() {
return Task.map(Time.now(), (currentTime) => Time.add(currentTime, TimeDuration.minutes(2)));
}

License

MIT © Julien Polo julien.polo@gmail.com

Index

Type Aliases

Time

Time: TimeType

Represent a time typically returned by Date.now()

TimeDuration

TimeDuration: TimeDurationType

Represent a duration in milliseconds

Page Options