question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Module '"@angular/fire/auth"' has no exported member 'AngularFireAuth'.ts(2305) . please help me to solve this issue

See original GitHub issue

Version info

Angular:

Firebase:

AngularFire:

Other (e.g. Ionic/Cordova, Node, browser, operating system):

How to reproduce these conditions

Failing test unit, Stackblitz demonstrating the problem

Steps to set up and reproduce

Sample data and security rules

Debug output

** Errors in the JavaScript console **

** Output from firebase.database().enableLogging(true); **

** Screenshots **

Expected behavior

Actual behavior

Issue Analytics

  • State:open
  • Created 2 years ago
  • Comments:6

github_iconTop GitHub Comments

4reactions
Sapythoncommented, Oct 22, 2021

An example of a signInAnonymously method in v7

import { Injectable } from '@angular/core';
import { Auth, signInAnonymously } from '@angular/fire/auth';
import { UserDataService } from '../userData/user-data.service';
@Injectable({
  providedIn: 'root'
})
export class AuthorizationService {
  constructor(private auth:Auth,private userData:UserDataService) {
    console.log('AuthorizationService',auth.name);
   }
   loginAnonymously(){
    signInAnonymously(this.auth).then(credential=>{
      console.log('signInAnonymously',credential);
      this.userData.addNewUser();
      console.log('add new user')
    });
   }

}

3reactions
Sapythoncommented, Oct 22, 2021

Import it in module like this. import {provideAuth, getAuth} from '@angular/fire/auth';

and then add this into the imports list in aap.module.ts

imports : [ provideAuth(() => getAuth()) ]

Read more comments on GitHub >

github_iconTop Results From Across the Web

"@angular/fire"' has no exported member 'AngularFireModule ...
I upgraded to "firebase": "~9.0.2" with npm i firebase@9.0.2; I made some corrections in the app.module.ts file: import ...
Read more >
Module firebase/app' has no exported member 'firestore'
https://codedocu.com/Software/Angular/Angular-Error/ Solved -Angular-Firebase-Fehler-TS2305_colon_- Module -firebase/app- has - no - exported - member - ...
Read more >
property 'auth' does not exist on type 'typeof import - You.com
As Per firebase type definitions firebase does not have default property. please change it as var defaultauth= firebase.auth(); and try. Open side panel....
Read more >
“Module '"@angular/fire/firestore"' has no exported member ...
I had the same problem. I solved it by following those steps : 2. ​. 3. 1/ First, you have to connect your...
Read more >
Using AngularFire in an Angular 7 library - Google Groups
import { AngularFireAuthModule } from '@angular/fire/auth'; ... I implement an environment in the new Angular 7, when the library has no environment file?...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found