1. Anuncie Aqui ! Entre em contato fdantas@4each.com.br

Firebase Phone Auth woks on web but not on IOS device

Discussão em 'Angular' iniciado por AlejoDev, Setembro 28, 2024 às 18:12.

  1. AlejoDev

    AlejoDev Guest

    I created an Ionic 8 + Capacitor + Firebase project and added the latest version of AngularFire to it.

    Everything works perfectly on Desktop but when I launch on my iPhone, there is an error appears on Xcode console: [error] - ERROR {"code":"auth/internal-error","customData":{},"name":"FirebaseError"}

    My app.module.ts looks like:

    import { NgModule } from '@angular/core';
    import { BrowserModule } from '@angular/platform-browser';
    import { RouteReuseStrategy } from '@angular/router';
    import { IonicModule, IonicRouteStrategy } from '@ionic/angular';
    import { AppComponent } from './app.component';
    import { AppRoutingModule } from './app-routing.module';
    import { initializeApp, provideFirebaseApp } from '@angular/fire/app';
    import { getAuth, provideAuth } from '@angular/fire/auth';
    import { environment } from 'src/environments/environment.prod';

    @NgModule({
    declarations: [AppComponent],
    imports: [BrowserModule,
    IonicModule.forRoot(),
    AppRoutingModule],
    providers: [{ provide: RouteReuseStrategy, useClass: IonicRouteStrategy },
    provideFirebaseApp(() => initializeApp(environment.firebaseConfig)),
    provideAuth(() => getAuth())],
    bootstrap: [AppComponent],
    })
    export class AppModule {}


    I've spent a lot of time trying various things but it doesn't work. I even installed the firebase sdk from xcode (I don't know if it's really necessary) and I also configured the GoogleService-Info.plist file, but the error still persists.

    Do you have any ideas how I can fix the problem ?

    Continue reading...

Compartilhe esta Página