I am using react-datepicker. I am trying to highlight the dates of next 2 weeks from the current date.I used the below code:
var endDate = new Date();
var numberOfDaysToAdd = 13;
endDate.setDate(endDate.getDate() + numberOfDaysToAdd);
var currDate = new Date();
<DatePicker
dateFormat="YYYY-MM-DD"
todayButton={"Today"}
selected={this.state.startDate}
onChange={this.handleChange}
highlightDates = {[currDate,endDate]}
/>
But it is not working. Please help me.