invertase / invertase/tanstack-query-firebase

FirebaseError: Type does not match the expected instance... different Firestore SDK?

Open
#68 5 comments 0 reactions 0 assignees View on GitHub
react-query-firebase
Dominant language
TypeScript
Stars
462
Forks
69
PR merge metrics
No merged PRs in 30d

Description

I'm working on an app in Nextjs 12 and everything appears to be working fine but I keep getting this error at build time about a different Firestore SDK:
```
error - unhandledRejection: [FirebaseError: Type does not match the expected instance. Did you pass a reference from a different Firestore SDK?] {
code: 'invalid-argument',
customData: undefined,
toString: [Function (anonymous)]
}
```
Everythig compiles and the site works fine aside from this error but I'd like to understand the problem if possible. Sorry I don't have much more to share, the error doesn't indicate much.

Here's more on my env:
```
"@react-query-firebase/firestore": "^1.0.0-dev.7",
"firebase": "^9.9.3",
"next": "12.2.5",
"react": "18.2.0",
"react-dom": "18.2.0",
"react-query": "3.*"
```
Edit: Should add that I am working in JS not TS.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.