From 6c64d16906b5a5d70405c3c8e689da37133fae12 Mon Sep 17 00:00:00 2001 From: Max Date: Mon, 30 Sep 2024 15:18:16 +0200 Subject: [PATCH] fix(sync): Disable browser broadcast Ensure the browser broadcast does not lead to out of sync docs. If a tab fails to send a step over the network it may still distributes it to a different tab / window via the browser broadcast. That other window will include the step in the yjs history without forwarding it to other parties. From that point on all changes in the second tab will depend on the step that other clients did not receive. Therefore these changes will not be applied at other parties. To prevent this scenario disable browser broadcast completely. Signed-off-by: Max --- src/components/Editor.vue | 1 + 1 file changed, 1 insertion(+) diff --git a/src/components/Editor.vue b/src/components/Editor.vue index 91e7e3bbc91..c82607fee01 100644 --- a/src/components/Editor.vue +++ b/src/components/Editor.vue @@ -403,6 +403,7 @@ export default { fileId: this.fileId, queue: this.$queue, initialSession: this.initialSession, + disableBC: true, }) this.$providers.push(syncServiceProvider) this.forceRecreate = false