Very Popular
Latest
function default
import { default } from "https://dotland.deno.dev/x/date_fns@v2.22.1/setMilliseconds/index.ts";

Examples

// Set 300 milliseconds to 1 September 2014 11:30:40.500: const result = setMilliseconds(new Date(2014, 8, 1, 11, 30, 40, 500), 300) //=> Mon Sep 01 2014 11:30:40.300

Parameters

dirtyDate: Date | number
  • the date to be changed
dirtyMilliseconds: number
  • the milliseconds of the new date

Returns

the new date with the milliseconds set