Skip to content

Fix persisteds having isolated reactivity #9305

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

Merged
merged 1 commit into from
Jul 7, 2025

Conversation

Caleb-T-Owens
Copy link
Contributor

This change makes persisteds behave like a singleton instance based on the key passed in.

This makes use of the JS WeakMap to make sure that they can still be GCed correctly

Copy link

vercel bot commented Jul 7, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
gitbutler-components ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 7, 2025 5:33pm
gitbutler-web ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 7, 2025 5:33pm

This change makes persisteds behave like a singleton instance based on the key passed in.

This makes use of the JS `WeakMap` to make sure that they can still be GCed correctly
@Caleb-T-Owens Caleb-T-Owens force-pushed the fix-persisteds-having-isolated-reactivity branch from 938aead to 1f40918 Compare July 7, 2025 17:31
@Caleb-T-Owens Caleb-T-Owens enabled auto-merge July 7, 2025 17:35
@Caleb-T-Owens Caleb-T-Owens merged commit 5f48769 into master Jul 7, 2025
20 checks passed
@Caleb-T-Owens Caleb-T-Owens deleted the fix-persisteds-having-isolated-reactivity branch July 7, 2025 17:36
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.

1 participant