Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't cache values for constants() call #5442

Merged
merged 3 commits into from
Sep 5, 2019

Conversation

ItsNoHax
Copy link
Collaborator

@ItsNoHax ItsNoHax commented Sep 2, 2019

Closes: #5439

The reason we can not cache the values is because the implementation differs per OS. Android returns static values while iOS will actually crawl the layout and return it's heights. The caching mechanism here meant that iOS would only return the heights of the layout it calculated the first time.

@ItsNoHax ItsNoHax requested a review from guyca September 2, 2019 13:28
Alberto Blanco added 2 commits September 2, 2019 15:58
The reason we can not cache the values is because the implementation differs per OS. Android returns static values while iOS will actually crawl the layout and return it's heights. The caching mechanism here meant that iOS would only return the heights of the layout it calculated the first time.
@guyca guyca merged commit a99e138 into wix:master Sep 5, 2019
@ItsNoHax ItsNoHax deleted the 5439-constants-values-cached branch January 14, 2020 14:12
vshkl pushed a commit to vshkl/react-native-navigation that referenced this pull request Feb 5, 2020
* Don't cache values for constants() call

The reason we can not cache the values is because the implementation differs per OS. Android returns static values while iOS will actually crawl the layout and return it's heights. The caching mechanism here meant that iOS would only return the heights of the layout it calculated the first time.

* Update docs regarding inconsistencies in Constants
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Constants don't get recalculated when layout changes
2 participants