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

Prevent creation of button react view with the same componentId #5687

Merged
merged 9 commits into from
Nov 27, 2019

Conversation

yogevbd
Copy link
Collaborator

@yogevbd yogevbd commented Nov 26, 2019

No description provided.

@guyca guyca merged commit 1807c5b into master Nov 27, 2019
@guyca guyca deleted the reuseReactComponents branch November 27, 2019 15:00
vshkl pushed a commit to vshkl/react-native-navigation that referenced this pull request Feb 5, 2020
…5687)

When updating buttons with mergeOptions, existing custom buttons are unmounted and then recreated. This commit adds an optimisation which prevents the react components from being recreated.
To avoid unnecessary recreation, add an `id` to the component. If an existing react view is found for that id, it will be reused.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants