Skip to content

Conversation

@bhgsbatista
Copy link
Contributor

@bhgsbatista bhgsbatista commented Sep 19, 2019

This fixes an issue where translation is not properly applied when data reference changes, ex:

https://codesandbox.io/s/nifty-wilson-xbfl8

It's also slightly better performant since we only call Tree.calculateD3Geometry(nextProps); once.

@bkrem
Copy link
Owner

bkrem commented Sep 20, 2019

Ah that was indeed silly with the early returns, thank you for fixing 💯 That syntax works for a single if case for getDerivedState but not for multiple that are not mutually exclusive.

@bkrem bkrem merged commit f46c145 into bkrem:master Sep 20, 2019
@bkrem
Copy link
Owner

bkrem commented Sep 20, 2019

Shipped as v1.15.3 🚀

Thank you again for helping push through this messiness around compat 👍

@bhgsbatista
Copy link
Contributor Author

bhgsbatista commented Sep 23, 2019

Np, it was a team effort :-P

@bhgsbatista bhgsbatista deleted the hotfix/241-better-react-15-compat branch September 23, 2019 01:53
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