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

Examples

// How many full quarters are between 31 December 2013 and 2 July 2014? var result = differenceInQuarters(new Date(2014, 6, 2), new Date(2013, 11, 31)) //=> 2

Parameters

dirtyDateLeft
  • the later date
dirtyDateRight
  • the earlier date