Skip to main content
Deno 2 is finally here 🎉️
Learn more
Very Popular
Go to Latest
function subMilliseconds
import { subMilliseconds } from "https://deno.land/x/date_fns@v2.0.0-beta.2/index.js";

Examples

// Subtract 750 milliseconds from 10 July 2014 12:45:30.000: var result = subMilliseconds(new Date(2014, 6, 10, 12, 45, 30, 0), 750) //=> Thu Jul 10 2014 12:45:29.250

Parameters

dirtyDate
  • the date to be changed
dirtyAmount
  • the amount of milliseconds to be subtracted