Skip to content

Sync sketch open in multiple places using web sockets #1249

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

Open
catarak opened this issue Jan 28, 2020 · 5 comments
Open

Sync sketch open in multiple places using web sockets #1249

catarak opened this issue Jan 28, 2020 · 5 comments

Comments

@catarak
Copy link
Member

catarak commented Jan 28, 2020

Nature of issue?

  • New feature request

New feature details:

If you have a sketch open in multiple tabs, whether it be the edit or the full screen views, if you edit the code in the edit view, the sketch does not update in the other tabs.

As discussed in #1234 comment, this could be handled in a variety of ways:

  • localStorage
  • serviceWorker
  • web sockets
  • ???
@plxity
Copy link
Contributor

plxity commented Jan 28, 2020

@catarak How can we use local storage in this? 🤔

WebSockets is a good idea to implement this feature.

@ashu8912
Copy link
Contributor

ashu8912 commented Feb 1, 2020

I think serviceWorker is the more preferred way.

@iainnash
Copy link

iainnash commented Feb 9, 2020

Would using something like https://github.com/AOHUA/redux-state-sync make sense?

@catarak
Copy link
Member Author

catarak commented Mar 24, 2020

This is on my mind as I was thinking about how to implement #1337. Would it perhaps make sense to solve this in the same way as handling updates for multiple users? Or should they be handled differently?

@catarak
Copy link
Member Author

catarak commented Feb 11, 2021

The solution is definitely to dispatch sketch updates via websockets, after #1759 is completed.

@catarak catarak changed the title When sketch is open in multiple tabs, versions can be out of sync Sync sketch open in multiple places using web sockets Feb 11, 2021
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

No branches or pull requests

4 participants