-
Notifications
You must be signed in to change notification settings - Fork 927
Remove MultiTabSyncEngine #3442
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
Conversation
💥 No ChangesetLatest commit: a70479b Merging this PR will not cause any packages to be released. If these changes should not cause updates to packages in this repo, this is fine 🙂 If these changes should be published to npm, you need to add a changeset. This PR includes no changesetsWhen changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types Click here to learn what changesets are, and how to add one. Click here if you're a maintainer who wants to add a changeset to this PR |
Binary Size ReportAffected SDKs
Test Logs |
7f24fca
to
e1cd35b
Compare
// online state (the local client may go offline, even though the primary | ||
// tab remains online) and only apply the primary tab's online state from | ||
// SharedClientState. | ||
if ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note: This combines the MultiTabSyncEngine's applyOnlineStateChange
with the SyncEngine's applyOnlineStateChange
. It is actually similar to what we had 6+ months ago.
@@ -75,7 +75,6 @@ export type ClientId = string; | |||
* assigned before calling `start()`. | |||
*/ | |||
export interface SharedClientState { | |||
syncEngine: SharedClientStateSyncer | null; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This field is now only part of WebStorageSharedClientState. Removing it made the general test setup a lot easier, since it is not accessed in most tests but would still have to be assigned.
This is similar to #3436 and removes the explicit MultiTabSyncEngine class. Instead, the methods are now tree-shakeable and will only be included with multi-tab IndexedDb persistence.
Much smaller diff: https://github.com/firebase/firebase-js-sdk/pull/3442/files?w=1
This is the second commit in #3425. The next PR will then rewrite the component provider.