Skip to content

Fix deprecation documentation #5286

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

Merged
merged 2 commits into from
Aug 12, 2021
Merged

Fix deprecation documentation #5286

merged 2 commits into from
Aug 12, 2021

Conversation

zwu52
Copy link
Member

@zwu52 zwu52 commented Aug 12, 2021

Deprecated method doc should start with "Use ...".

This will fix: b/170682742

@zwu52 zwu52 requested a review from egilmorez as a code owner August 12, 2021 17:25
@changeset-bot
Copy link

changeset-bot bot commented Aug 12, 2021

⚠️ No Changeset found

Latest commit: 71c4fb3

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When 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

@zwu52 zwu52 requested a review from hsubox76 August 12, 2021 17:25
@github-actions
Copy link
Contributor

Changeset File Check ⚠️

  • Changeset formatting error in following file:
    Package "firebase-compat-typings-test" must depend on the current version of "firebase-exp": "9.0.0-beta.8" vs "file:../../packages-exp/firebase-exp"
    Package "firebase-compat-typings-test" must depend on the current version of "firebase-exp": "9.0.0-beta.8" vs "file:../../packages-exp/firebase-exp"
    Package "firebase-compat-typings-test" must depend on the current version of "firebase-exp": "9.0.0-beta.8" vs "file:../../packages-exp/firebase-exp"
    Some packages have been changed but no changesets were found. Run `changeset add` to resolve this error.
    If this change doesn't need a release, run `changeset add --empty`.
    

@google-oss-bot
Copy link
Contributor

google-oss-bot commented Aug 12, 2021

Binary Size Report

Affected SDKs

No changes between base commit (e83826a) and head commit (f63d962).

Test Logs

Copy link
Contributor

@egilmorez egilmorez left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this be backticked, or will it be rendered as code font without them?

@google-oss-bot
Copy link
Contributor

google-oss-bot commented Aug 12, 2021

Size Analysis Report

Affected Products

No changes between base commit (e83826a) and head commit (f63d962).

@@ -7419,7 +7419,7 @@ declare namespace firebase.messaging {
*
* @param callback The function to handle the push message.
*
* @deprecated onBackgroundMessage(nextOrObserver: firebase.NextFn<MessagePayload>|
* @deprecated Use onBackgroundMessage(nextOrObserver: firebase.NextFn<MessagePayload>|
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, will this fix the way this item gets conflated with the following Observer-Unsubscribe item?

Ideally we'd have a way to gen the docs and eyeball that.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Those all belong together, the Observer and error are part of the signature and the Unsubscribe is the return type. There could be some spaces before the | and after the comma after errorFn,. But actually, do we need the whole signature here, can we just say "Use onBackgroundMessage()" or "Use {@link firebase.messaging.Messaging.onBackgroundMessage}"?

Docs can be generated locally by running

yarn
yarn docgen:js

at the root of the repo.

After running that, the affected html file will be found at scripts/docgen/html/js/firebase.messaging.Messaging.html

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added some spaces.

Don't know if should use the full method signature of {@link firebase.messaging.Messaging.onBackgroundMessage}. If later, need to change other ones.

@zwu52 zwu52 merged commit bfeac26 into master Aug 12, 2021
@zwu52 zwu52 deleted the fix_deprecated_doc branch August 12, 2021 20:04
@firebase firebase locked and limited conversation to collaborators Sep 12, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants