Skip to main content
The Deno 2 Release Candidate is here
Learn more
Module

x/complaindate/utils/addYears.ts>addYears

JavaScript date-time utilities that keeps timezones on the surface
Go to Latest
function addYears
import { addYears } from "https://deno.land/x/complaindate@v0.7.2/utils/addYears.ts";

Get a function curried with a number of years to add to its plain-date arguments.

Parameters

years: number

The number of years to add or subtract

Returns

<T extends ComPlainDate>(date: T) => T

A curried function that operates on plain-dates