[馃悰] 馃敟Filter.and
and Filter.or
should be able to accept Filter.and
or Filter.or
as their argument
#7850
Open
2 of 10 tasks
Labels
Issue
According to the document
Filter.or
andFilter.and
should be able to accept themselves as arg:(Note that I've updated
Filter
tofirestore.Filter
due to this issue)However this throws type error:
![釀夅叧釀忈叧釀呩叺釂剦釁a喓 2024-06-19 釀嬦叐釀掅叜 4 09 52](https://private-user-images.githubusercontent.com/13231564/340909204-0c1f0d4b-a61b-42ef-9ade-5b7411d9ff32.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjAxMTIzNTEsIm5iZiI6MTcyMDExMjA1MSwicGF0aCI6Ii8xMzIzMTU2NC8zNDA5MDkyMDQtMGMxZjBkNGItYTYxYi00MmVmLTlhZGUtNWI3NDExZDlmZjMyLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA3MDQlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwNzA0VDE2NTQxMVomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTk1NzMxMzc0MjJiZTE2ODYwMjE0MjYyNzhkN2Y1ZjY2MmVjZWQ2NWNlMzUwMzcwZWFiYmQ2MTljMjQxMzYyZWImWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.Kh8f48gVUaklpyw1pny8kzkecmYB_B5m9TR_kY2C1JQ)
This is happening because type of
Filter.or
andFilter.and
only accepts type ofQueryFilterConstraint
while what they're returning is type ofQueryCompositeFilterConstraint
:react-native-firebase/packages/firestore/lib/index.d.ts
Lines 71 to 87 in ca07cad
So to address this issue, their type needs to be adjusted to accept either
QueryFilterConstraint
orQueryCompositeFilterConstraint
:This works as I tested by updating the file in
node_modules
.But will the change introduce any other issues that I'm not aware of?
Project Files
Managed expo
Javascript
Click To Expand
package.json
:firebase.json
for react-native-firebase v6:# N/A
iOS
Click To Expand
ios/Podfile
:# N/A
AppDelegate.m
:// N/A
Android
Click To Expand
Have you converted to AndroidX?
android/gradle.settings
jetifier=true
for Android compatibility?jetifier
for react-native compatibility?android/build.gradle
:// N/A
android/app/build.gradle
:// N/A
android/settings.gradle
:// N/A
MainApplication.java
:// N/A
AndroidManifest.xml
:<!-- N/A -->
Environment
Click To Expand
react-native info
output:react-native-firebase
version you're using that has this issue:20.0.0
Firebase
module(s) you're using that has the issue:Firestore
TypeScript
?Y
&5.3.3
React Native Firebase
andInvertase
on Twitter for updates on the library.The text was updated successfully, but these errors were encountered: