onefinestay / react-daterange-picker

Other
563 stars 209 forks source link

Show all month in a year? #163

Closed fa10 closed 6 years ago

fa10 commented 7 years ago

Hi,

I am trying to show all months of a year, but can get the initialMonth prop working it is starting from February instead of January.

<DateRangePicker
     firstOfWeek={1}
     numberOfCalendars={12}
     selectionType='range'
     initialMonth={1}
     initialYear={2016}
     stateDefinitions={stateDefinitions}
     defaultState="available" />
AlanFoster commented 7 years ago

@fa10 if you supply the starting month of 0, does this work as expected?

fa10 commented 7 years ago

No @AlanFoster it is not working when using 0. I got it working by using initialFromValue and then supply value with a moment date.

james-ff commented 6 years ago

@AlanFoster Related to #195?

AlanFoster commented 6 years ago

This should be fixed in 2.0.1, please raise a new issue if there are any problems