Angular2 fire fails Namespace 'firebase' has no exported member 'Promise'

Viewed 2033

I have installed angular2 fire

 "angularfire2": "^5.0.0-rc.0",

Now in my app module(root module)

export const firebaseConfig = {
  apiKey: "mykey",
  authDomain: "....",
  databaseURL: "...",
  projectId: "...",
  storageBucket: "...",
  messagingSenderId: "..."
};

imports:[
    AngularFireModule.initializeApp(firebaseConfig), 
    AngularFireDatabaseModule
 ]

Now am geting an error

 Class 'FirebaseApp' incorrectly implements interface 'App'.
  Property 'firestore' is missing in type 'FirebaseApp'.


node_modules/angularfire2/firebase.app.module.d.ts (12,28):
  Namespace 'firebase' has no exported member 'Promise'.

Where am i going wrong or what else do i need to add to have it work

2 Answers

firebase.Promise was removed in Firebase 4.5.0. "angularfire2": "^5.0.0-rc.2" accounts for this change. This version should solve the issue you're having.

run npm install anularfire2 --save command it should work

Related