MCPcopy Create free account
hub / github.com/UI5/webcomponents / getDaysInMonth

Function getDaysInMonth

packages/localization/src/dates/getDaysInMonth.ts:3–9  ·  view source on GitHub ↗
(date: CalendarDate)

Source from the content-addressed store, hash-verified

1import CalendarDate from "./CalendarDate.js";
2
3const getDaysInMonth = (date: CalendarDate) => {
4 const tempCalendarDate = new CalendarDate(date);
5 tempCalendarDate.setDate(1);
6 tempCalendarDate.setMonth(tempCalendarDate.getMonth() + 1);
7 tempCalendarDate.setDate(0);
8 return tempCalendarDate.getDate();
9};
10
11export default getDaysInMonth;

Callers 1

Calls 4

setDateMethod · 0.95
setMonthMethod · 0.95
getMonthMethod · 0.95
getDateMethod · 0.95

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…