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

millisecondsToSeconds

import { millisecondsToSeconds } from "https://esm.sh/v135/date-fns@3.6.0/index.d.mts";
@example
// Convert 1000 miliseconds to seconds:
const result = millisecondsToSeconds(1000)
//=> 1
@example
// It uses floor rounding:
const result = millisecondsToSeconds(1999)
//=> 1
function millisecondsToSeconds(milliseconds: number): number;
§
millisecondsToSeconds(milliseconds: number): number
[src]

§Parameters

§
milliseconds: number
[src]
  • The number of milliseconds to be converted

§Return Type

§
number
[src]

The number of milliseconds converted in seconds