getWeekYear
Modified on Tue, 22 Aug 2023
Description
Use this function to get the local week-numbering year of the given date.
Syntax
getWeekYear(date:Date | number, options:undefined):number
Returns
Return Value | Description |
---|---|
Number | Returns the local week-numbering year of the given date. |
Sample
Example | Result | Description |
---|---|---|
getWeekYear(2023-04-08) | 2023 | The function calculates the local week-numbering year of the given date, which is 2023, and returns it. |
To view all the Date functions, click here.
See Also
Was this article helpful?
That’s Great!
Thank you for your feedback
Sorry! We couldn't be helpful
Thank you for your feedback
Feedback sent
We appreciate your effort and will try to fix the article