-
Notifications
You must be signed in to change notification settings - Fork 2.2k
ERROR TypeError: Object(…) is not a function” using AngularFirestore and firebase #1668
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
Comments
Same here. I am getting this error on a previously working project after upgrading angularfire2 from |
I'm also getting same after updating to rc.9 also. |
Same here after updating to |
Same here |
Help us @davideast, you're our only hope! |
This comment has been minimized.
This comment has been minimized.
@Zediz your stacktrace mentions Can anyone else on the thread can confirm if this is the issue? |
This comment has been minimized.
This comment has been minimized.
@diego-lipinski-de-castro let's please keep the conversation to the error at hand. |
Closing for now, since I'm 99% sure that's what the issue is. |
Yeah, solved this issue, the problem now is with rxjs => Cannot find module "rxjs-compat/Observable" |
@diego-lipinski-de-castro are you the one trying to import Observable or is it a lib? Observable can be imported from rxjs: |
For reference here's the RXJS 5 => 6 migration guide. |
I needed to install rxjs-compat, after that I updated all packaged and it's working |
@jamesdaniels Yes. It solved the issue. |
Will it be possible to use this library also without rxjs-compat? |
Thank you, Nox04. |
thx Nox04 u save me |
In order to build out my app, I had to update angular fire from rc6 to [email protected]. Now there an error when using firestore: "TypeError: Object(...) is not a function at new AngularFirestore". The solution is likely to do with rxjs: angular/angularfire#1668 My current RXJS is "rxjs": "5.5.2".
@Nox04 am facing this issue after install rxjs, can u help me pls ??? in ../../node_modules/rxjs/internal/types.d.ts(81,44): error TS1005: ';' e xpected. |
with me, it happend when I built with mode production. I can fix it by adding the bold line: imports: [ |
@Fjnova Thanks, had the same issue with production mode and that solved it! |
@Fjnova you are genius I have resolved that issue too but the module name is different AngularFireDatabaseModule import { AngularFireDatabase, AngularFireDatabaseModule } from '@angular/fire/database'; imports: [ |
In my case the error was Object(...).auth is not a function, so adding the AngularFireAuthModule solved the issue and production build is now working, thank you to @Fjnova for the hint |
Thanks @Fjnova, I was crazy trying to find the solution to this problem, finally I was missing the importation of AngularFireAuthModule and AngularFirestoreModule |
I want to use firebase and angularfire2 in my app, first of all, I installed them, and for the declarations:
in environment.ts
in app.module.ts, imports:
in the component where want to get my data:
import { AngularFirestore } from 'angularfire2/firestore';
until this moment I have not an error, but when I want to declare my variable in the constructor to use it:
I have an error:
and I don't know why?
thanks for your help
The text was updated successfully, but these errors were encountered: