Skip to content

fix: prevent vanilla share collisions across keys#57

Merged
wobsoriano merged 2 commits into
mainfrom
fix/vanilla-share-key-collision
Mar 24, 2026
Merged

fix: prevent vanilla share collisions across keys#57
wobsoriano merged 2 commits into
mainfrom
fix/vanilla-share-key-collision

Conversation

@wobsoriano

@wobsoriano wobsoriano commented Mar 24, 2026

Copy link
Copy Markdown
Owner

Summary

  • fix share() to track a per-key serialized snapshot so unrelated store key updates do not rebroadcast on other shared keys
  • keep existing $patch update path and avoid adding new runtime dependencies
  • add a regression test that verifies sharing key a does not trigger a broadcast for shared key b

Verification

  • vp test run src/__tests__/vanilla.test.ts
  • vp lint src/vanilla.ts src/__tests__/vanilla.test.ts

Fixes #51

@wobsoriano wobsoriano merged commit a655f3c into main Mar 24, 2026
2 checks passed
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.

Vanilla share of multiple keys in same store collides

1 participant