The daysInMonth() method returns the number of days in the specified month.
DayPilot.Date.daysInMonth();
Number of days.
var daysInFebruary = new DayPilot.Date("2020-02-01").daysInMonth(); // 29 var daysInMarch = new DayPilot.Date("2020-03-15").daysInMonth(); // 31