Skip to content
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

Add default converter option in withConverter() #4577

Merged
merged 4 commits into from
Mar 8, 2021
Merged

Conversation

thebrianchen
Copy link

Porting from node.

@changeset-bot
Copy link

changeset-bot bot commented Mar 2, 2021

🦋 Changeset detected

Latest commit: 45aba16

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 9 packages
Name Type
firebase Patch
@firebase/firestore Patch
@firebase/firestore-types Patch
@firebase/rules-unit-testing Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@google-oss-bot
Copy link
Contributor

google-oss-bot commented Mar 2, 2021

Binary Size Report

Affected SDKs

  • @firebase/firestore

    Type Base (529a13a) Head (81e6d80) Diff
    browser 259 kB 259 kB +90 B (+0.0%)
    esm2017 201 kB 202 kB +90 B (+0.0%)
    main 530 kB 530 kB +135 B (+0.0%)
    module 259 kB 259 kB +90 B (+0.0%)
    react-native 201 kB 202 kB +90 B (+0.0%)
  • @firebase/firestore/bundle

    Type Base (529a13a) Head (81e6d80) Diff
    browser 266 kB 266 kB +90 B (+0.0%)
    esm2017 155 kB 155 kB +90 B (+0.1%)
    main 526 kB 526 kB +135 B (+0.0%)
    module 266 kB 266 kB +90 B (+0.0%)
    react-native 155 kB 155 kB +90 B (+0.1%)
  • @firebase/firestore/memory

    Type Base (529a13a) Head (81e6d80) Diff
    browser 196 kB 196 kB +90 B (+0.0%)
    esm2017 152 kB 152 kB +90 B (+0.1%)
    main 324 kB 324 kB +135 B (+0.0%)
    module 196 kB 196 kB +90 B (+0.0%)
    react-native 152 kB 152 kB +90 B (+0.1%)
  • @firebase/firestore/memory-bundle

    Type Base (529a13a) Head (81e6d80) Diff
    browser 204 kB 204 kB +90 B (+0.0%)
    esm2017 155 kB 155 kB +90 B (+0.1%)
    main 321 kB 321 kB +135 B (+0.0%)
    module 204 kB 204 kB +90 B (+0.0%)
    react-native 155 kB 155 kB +90 B (+0.1%)
  • firebase

    Type Base (529a13a) Head (81e6d80) Diff
    firebase-firestore.js 304 kB 304 kB +90 B (+0.0%)
    firebase-firestore.memory.js 243 kB 243 kB +90 B (+0.0%)
    firebase.js 844 kB 844 kB +90 B (+0.0%)

Test Logs

@google-oss-bot
Copy link
Contributor

google-oss-bot commented Mar 2, 2021

Size Analysis Report

Affected Products

No changes between base commit (529a13a) and head commit (81e6d80).

Copy link
Contributor

@schmidt-sebastian schmidt-sebastian left a comment

Choose a reason for hiding this comment

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

Thanks!

): PublicDocumentReference<U>;
withConverter<U>(
converter: PublicFirestoreDataConverter<U> | null
): PublicDocumentReference<U> | PublicDocumentReference<PublicDocumentData> {
Copy link
Contributor

Choose a reason for hiding this comment

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

In Node, this is just PublicDocumentReference<U> and TypeScript deduces U.

withConverter<U>(converter: PublicFirestoreDataConverter<U>): Query<U>;
withConverter<U>(
converter: PublicFirestoreDataConverter<U> | null
): Query<U> | Query<DocumentData> {
Copy link
Contributor

Choose a reason for hiding this comment

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

Same as above.

): CollectionReference<U>;
withConverter<U>(
converter: PublicFirestoreDataConverter<U> | null
): CollectionReference<U> | CollectionReference<PublicDocumentData> {
Copy link
Contributor

Choose a reason for hiding this comment

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

And one more for old times sake.

This was referenced Mar 12, 2021
@firebase firebase locked and limited conversation to collaborators Apr 8, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants