Please make our job easier by filling this template out to completion. If you're requesting a feature instead of reporting a bug, please feel free to skip the Environment and Reproducible Demo sections.
I set style={{ width: width - 54, height: 300 }}.
width changes fine with the given input, but height stays the same regardless of the value I put in for height.
I set style={{ width: width - 54, height: 300 }}, and expected the height to fit in.
height did not change
If there's an error message, please paste the full terminal output and error message in this code block:
Error text goes here!
Please run these commands in the project folder and fill in their results:
npm ls react-native-calendars: 1.170npm ls react-native: 0.59.4Also specify:
Please provide a minimized reproducible demonstration of the problem you're reporting.
Issues that come with minimal repro's are resolved much more quickly than issues where a maintainer has to reproduce themselves.
Changing the calendar height doesn't trigger a state change and so the calendar won't re-render.
If you want the calendar to re-render change something that actually sets the state on the calendar list.
Take a look at the component to see the props that trigger a re-render https://github.com/wix/react-native-calendars/blob/master/src/calendar-list/index.js
I do not want to re-render the calendar. I simply want to set the default height of the calendar. I am not using a calendarList. I am using a simple calendar.
HI @seongminchoob
Use this calendarHeight={335}
I hope it solves your Problem.
How can I change height of calendarList? I tried using calendarHeight but had to deal with calendar being cropped.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Most helpful comment
HI @seongminchoob
Use this calendarHeight={335}
I hope it solves your Problem.