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

chore(connections): make sure that getThemeOf method gets updated when colors change #6162

Merged
merged 1 commit into from
Aug 28, 2024

Conversation

gribnoysup
Copy link
Collaborator

Follow-up to the big connections refactor I just merged, spotted an issue with this hook when working on refactor, but kept the fix out just to limit the scope of previous PR.

The fix itself is pretty straightforward: just make sure that method depends on actual list of data it needs and not on a stable getter. Maybe a good example to keep in mind for how easy it is to mess up state updates when React hooks are used and how vigilant you need to be when specifying dependencies (including making sure that dependencies used will actually update too)

@gribnoysup gribnoysup merged commit fc7d817 into main Aug 28, 2024
27 checks passed
@gribnoysup gribnoysup deleted the fix-get-theme-of-hook branch August 28, 2024 11:04
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