Skip to content

Version 9 Typings for auth.ProviderId #4853

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

Closed
cdcarson opened this issue Apr 29, 2021 · 2 comments
Closed

Version 9 Typings for auth.ProviderId #4853

cdcarson opened this issue Apr 29, 2021 · 2 comments

Comments

@cdcarson
Copy link

Describe your environment

  • Operating System version: MacOs 11.2.3
  • Browser version: n/a
  • Firebase SDK version: 9.0.0-beta.1
  • Firebase Product: auth

Bug

There seems to be a problem with the typings in @firebase/auth/dist/auth-exp-public.d.ts. On a freshly created Angular app I'm getting the following error trying to import getAuth:

Error: node_modules/@firebase/auth/dist/auth-exp-public.d.ts:3576:28 - error TS2694: 
Namespace '".../node_modules/@firebase/auth/dist/auth-exp-public".ProviderId' has no exported member 'FIREBASE'.

Steps to reproduce:

  • create an Angular app with ng new
  • import getAuth

Relevant Code:

// app.component.ts
import { Component } from '@angular/core';
import { initializeApp, FirebaseApp } from 'firebase/app';
import { getAuth } from 'firebase/auth';
import { environment } from '../environments/environment';

@Component({
  selector: 'app-root',
  templateUrl: './app.component.html',
  styleUrls: ['./app.component.scss']
})
export class AppComponent {

  constructor(
  ) {
    const app: FirebaseApp = initializeApp(environment.firebase);
    console.log(app)
  }

}

Note that if you comment out the getAuth import, the Angular app compiles, and the Firebase app is initialized properly.

@cdcarson cdcarson changed the title Version 9 Typescript Version 9 Typings for auth.ProviderId Apr 29, 2021
@Feiyang1
Copy link
Member

It has been fixed by #4821. It will be released in the next release.

@Feiyang1 Feiyang1 added the v9 label Apr 30, 2021
@Feiyang1
Copy link
Member

It has been fixed in 9.0.0-beta.2.

@firebase firebase locked and limited conversation to collaborators Jun 13, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants