Skip to main content
Module

x/date_fns/index.js>addMinutes

date-fns Deno package
Very Popular
Go to Latest
function addMinutes
import { addMinutes } from "https://deno.land/x/date_fns@v2.15.0/index.js";

Examples

// Add 30 minutes to 10 July 2014 12:00:00: var result = addMinutes(new Date(2014, 6, 10, 12, 0), 30) //=> Thu Jul 10 2014 12:30:00

Parameters

dirtyDate
  • the date to be changed
dirtyAmount
  • the amount of minutes to be added. Positive decimals will be rounded using Math.floor, decimals less than zero will be rounded using Math.ceil.