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

Feat/synchronize windows #72

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

OwenDelahoy
Copy link

This PR uses the storage event so that when the localStorage is modified outside of the application it is synchronized back to recoil.

This allows for synchronization of state between multiple tabs/windows/iframe, and updates the application's recoil state when a developer edits the localState within "Application" tab of chrome DevTools.

With the addStorageListener property of PersistConfiguration, the functionality can be adapted to storage configurations other than the localStorage, or if this is undesired, it can be disabled.

@polemius polemius force-pushed the master branch 2 times, most recently from 050c87f to 2f70d34 Compare May 17, 2023 06:56
@OwenDelahoy
Copy link
Author

@polemius I've updated this PR to resolve conflicts

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.

None yet

1 participant