Hi there! Are you looking for the official Deno documentation? Try docs.deno.com for all your Deno learning needs.

milliseconds

import { milliseconds } from "https://esm.sh/v135/date-fns@3.6.0/index.d.mts";
@example
// 1 year in milliseconds
milliseconds({ years: 1 })
//=> 31556952000

// 3 months in milliseconds
milliseconds({ months: 3 })
//=> 7889238000
function milliseconds({ years, months, weeks, days, hours, minutes, seconds }: Duration): number;
§
milliseconds({ years, months, weeks, days, hours, minutes, seconds }: Duration): number
[src]

§Parameters

§
{ years, months, weeks, days, hours, minutes, seconds }: Duration
[src]

§Return Type

§
number
[src]

The milliseconds