-
Notifications
You must be signed in to change notification settings - Fork 944
Rename multi-tab setting to synchronizeTabs #1728
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
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.
LGTM with nits (sorry).
settings.synchronizeTabs !== undefined | ||
? settings.synchronizeTabs | ||
: settings.experimentalTabSynchronization, | ||
DEFAULT_SYNCHRONIZE_TABS |
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.
Way to go naming the default correctly ahead of time!
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.
Why do you assume the API proposal wasn't based on this name? :)
if (settings) { | ||
if (settings.experimentalTabSynchronization !== undefined) { | ||
log.error( | ||
'The `experimentalTabSynchronization` setting has been renamed to ' + |
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 is probably super nitty but I don't think we usually use backticks within log messages. I'd remove or replace with '
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.
I didn't like the message without any quoting, but I am fine just using single quotes.
if (settings.experimentalTabSynchronization !== undefined) { | ||
log.error( | ||
'The `experimentalTabSynchronization` setting has been renamed to ' + | ||
'`synchronizeTabs`. In a future release, the setting will be removed ' + |
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.
extra space in setting will
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.
Ugh, I thought I fixed this before sending this out. It's fixed now.
log.error( | ||
'The `experimentalTabSynchronization` setting has been renamed to ' + | ||
'`synchronizeTabs`. In a future release, the setting will be removed ' + | ||
'and it is recommended that you remove it from your ' + |
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.
I might be overly paranoid but I worry "the setting will be removed" and "recommend that you remove it" could potentially be ambiguous and lead people to remove the setting entirely. Perhaps:
In a future release, 'experimentalTabSynchronization' will be removed, so you should update your firestore.enablePersistence() call to use 'synchronizeTabs' now.
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.
Sure, that works and reduces code duplication :)
Back to you Mike for merging! Thanls |
cc/ @Feiyang1 Another change for the next release... |
Note: To be merged into next major release.