Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/date_fns/index.js>setISOWeek

date-fns Deno package
Go to Latest
function setISOWeek
import { setISOWeek } from "https://deno.land/x/date_fns@v2.0.0-alpha.34/index.js";

Examples

// Set the 53rd ISO week to 7 August 2004: var result = setISOWeek(new Date(2004, 7, 7), 53) //=> Sat Jan 01 2005 00:00:00

Parameters

dirtyDate
  • the date to be changed
dirtyISOWeek
  • the ISO week of the new date