Hi am very new to this Date Range Picker and am done Date Range Picker in Type script showing single month but I need to show two months, Please help me in building the calendar showing two months
This is the code I had done to show calendar for one month but I need two months to show please help me .
public createCalender(month) {
const firstDay = moment(month).startOf('M');
const days = Array.apply(null, {length: month.daysInMonth()})
.map(Number.call, Number)
.map((n) => {
return moment(firstDay).add(n, 'd');
});
for (let n = 0; n < firstDay.weekday(); n++) {
days.unshift(null);
}
return days;
}
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Hi am very new to this Date Range Picker and am done Date Range Picker in Type script showing single month but I need to show two months, Please help me in building the calendar showing two months
This is the code I had done to show calendar for one month but I need two months to show please help me .
public createCalender(month) {
const firstDay = moment(month).startOf('M');
const days = Array.apply(null, {length: month.daysInMonth()})
.map(Number.call, Number)
.map((n) => {
return moment(firstDay).add(n, 'd');
});
for (let n = 0; n < firstDay.weekday(); n++) {
days.unshift(null);
}
return days;
}