bibekg / react-schedule-selector

A mobile-friendly when2meet-style grid-based schedule selector
MIT License
147 stars 51 forks source link

Updating the component when startDate changes #24

Closed kyletsm closed 4 years ago

kyletsm commented 4 years ago

Hi I am having an issue about changing startDate in order to essentially cycle through weeks at a time. I have a button set up to change the startDate state and tried to forceUpdate in order to refresh the scheduling table but the dates do not change. When I console.log(this.state) the startDate was increased by a week.

bibekg commented 4 years ago

Interesting use case but unfortunately the component currently doesn't support it. 😞 The set of dates to render cells for is determined in the component's constructor. I've been considering a rehaul of the component architecture and will mark this as one of the things to address in it!

bibekg commented 4 years ago

Just published v3.0 which enables this use case! Let me know if you have any questions.