I am trying to make it so that in react-day-picker, only the dates that are available are selectable (i.e. A user is only available for two days, all those other days are disabled and unselectable). I've tried doing this method:
<DayPicker
selectedDays={this.state.selectedDays}
onDayClick={this.handleDayClick}
disabledDays={(day => (day !== ServiceRequestEngagementCreateModal.availableDates(service.available_dates)))}
/>
But that makes all of the dates unavailable.
Any help would be appreciated, thanks!