react-bootstrap-datetimerangepicker
react-bootstrap-datetimerangepicker copied to clipboard
Calendar doesn't update on changing properties such as showCustomRangeLabel
Usecase: I need to display the calendar on 2 different pages in a web application with different options. One page shows the full calendar with showCustomRangeLabel and alwaysShowCalendars set to true. The other page just shows the calendar with some predefined ranges by setting showCustomRangeLabel and alwaysShowCalendars set to false.
Problem: The calendar doesn't update when I switch between pages. I verified that I am passing the correct options to the calendar
How to reproduce: One way to verify what I am saying is by following the steps below
Start a timer and toggle alwaysShowCalendars and showCustomRangeLabel passed to react-bootstrap-timepicker every few seconds. You will see that the calendar doesn't display correctly according to the values passed to it
yeah we have the same problem, calling .initializeDateRangePicker
on the existing picker seems to solve the issue