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

We should hook navigator.online to know when to try and send a push and pull again. #1019

Open
aboodman opened this issue Aug 7, 2022 · 3 comments
Labels
Fixit Small fix that should go in next release given time

Comments

@aboodman
Copy link
Contributor

aboodman commented Aug 7, 2022

This is marginally useful in the real world, but during development is very useful. Devs frequently use the "offline" feature when developing or testing and it would be great if Replicache came back right away from being offline when this happened.

@arv
Copy link
Contributor

arv commented Aug 23, 2022

If we do this we should probably put the logic in ConnectionLoop

We could also potentially only do this in debug mode.

@aboodman
Copy link
Contributor Author

We could also potentially only do this in debug mode.

It would also help a lot for demos, e.g.., replicache-todo. People frequently disconnect network on their device to test these demos. It will be more satisfying demo if sync happens immediately on reconnect.

@aboodman
Copy link
Contributor Author

If we do this we should probably put the logic in ConnectionLoop

👍

@arv arv added the Fixit Small fix that should go in next release given time label Oct 20, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Fixit Small fix that should go in next release given time
Projects
None yet
Development

No branches or pull requests

2 participants