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

fix(firestore): expose modular Filter and it's proper types #7884

Merged
merged 4 commits into from
Jul 10, 2024

Conversation

russellwheatley
Copy link
Member

Description

Tested with the following:

import { collection, Filter, getFirestore } from '@react-native-firebase/firestore';

import React from 'react';
import { AppRegistry, Button, Text, View } from 'react-native';

const snapshot = collection(getFirestore(), 'playground').where(
  Filter.and(Filter('bar', '==', 'baz'), Filter('foo', '==', 'bar')),
);

also get proper typing for Filter:
Screenshot 2024-07-08 at 15 11 29

Related issues

fixes #7134

Release Summary

Checklist

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
    • Yes
  • My change supports the following platforms;
    • Android
    • iOS
  • My change includes tests;
    • e2e tests added or updated in packages/\*\*/e2e
    • jest tests added or updated in packages/\*\*/__tests__
  • I have updated TypeScript types that are affected by my change.
  • This is a breaking change;
    • Yes
    • No

Test Plan


Think react-native-firebase is great? Please consider supporting the project with any of the below:

Copy link

vercel bot commented Jul 8, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
react-native-firebase ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 9, 2024 3:05pm

Copy link

codecov bot commented Jul 9, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 67.87%. Comparing base (7ee88cf) to head (ef44766).

Additional details and impacted files
@@             Coverage Diff             @@
##             main    #7884       +/-   ##
===========================================
+ Coverage   25.38%   67.87%   +42.50%     
===========================================
  Files         154      154               
  Lines        6137     6137               
  Branches     1266     1266               
===========================================
+ Hits         1557     4165     +2608     
+ Misses       3917     1868     -2049     
+ Partials      663      104      -559     

Lyokone
Lyokone previously approved these changes Jul 9, 2024
Salakar
Salakar previously approved these changes Jul 9, 2024
Copy link
Contributor

@Salakar Salakar left a comment

Choose a reason for hiding this comment

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

LGTM

Ideally a simple test would be good here to ensure this export is there and functions

@russellwheatley russellwheatley dismissed stale reviews from Salakar and Lyokone via 8e0df33 July 9, 2024 14:56
@Salakar Salakar merged commit 272efe5 into main Jul 10, 2024
19 checks passed
@Salakar Salakar deleted the firestore-7134 branch July 10, 2024 01:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[📚] Documentation Issue - FilterFunction
3 participants