Building A User Authentication Service with Angular and Firebase

Поделиться
HTML-код
  • Опубликовано: 22 окт 2024

Комментарии • 28

  • @aram5642
    @aram5642 5 лет назад

    A wonderful starter. Seems like the auxiliary user fields present on the Authentication record (displayName, phoneNumber) are better stored in a dedicated table instead.
    I was wondering while watching this video, what would be the best way to structure users and roles for enterprise apps...

  • @XTpF4vaQEp
    @XTpF4vaQEp 5 лет назад

    Like a childs play, yet so powerful.

  • @ClaytonAllenFP
    @ClaytonAllenFP 6 лет назад +1

    Thanks a bunch for making this video! I was pulling my hair out trying to sift through mounds of irrelevant documentation. Is there any way you could expound upon implementing this method with an CanActivate Auth guard? Cheers!

  • @nammsy
    @nammsy 5 лет назад +1

    your voice is like the villain from the moviel Phone Booth :P nice tutorial BTW!

  • @towpro2880
    @towpro2880 6 лет назад +3

    Thank you. Can you do do a tutorial using the new @angular/fire package instead?

    • @towpro2880
      @towpro2880 5 лет назад +1

      @oluwajoba emmanuel I figured it out it's basically the same thing you just have to add an instance of AngularFireDatabase from @angular/fire into your component or service's constructor and the rest is basically the same.

  • @vongodric
    @vongodric 6 лет назад +2

    Thank you for the video - was great help for me with getting started with authentication.

  • @mbaljeetsingh
    @mbaljeetsingh 6 лет назад

    I'm assuming you're using Windows. Can you tell me what are you using to show the opened tabs at the bottom?

    • @sayantanroy5996
      @sayantanroy5996 6 лет назад +2

      Actually he's using KDE based linux distro.

  • @enriquegreen7369
    @enriquegreen7369 4 года назад

    Hey thanks for the great vid, i have a problem though when i try to compile i get an error about missing dependencies. I cant find a fix so far, do you have any idea what it can be?
    ERROR in The target entry-point "@angular/fire" has missing dependencies:
    - @angular/core
    - @angular/common
    - rxjs
    - rxjs/operators

  • @Halissonskalee
    @Halissonskalee 5 лет назад

    Hi! i need help Property 'object' does not exist on type 'AngularFireDatabaseModule'?

  • @gadeichhorn
    @gadeichhorn 4 года назад

    brilliant! thanks for making this tutorial.

  • @luisstiventrujilloortiz8734
    @luisstiventrujilloortiz8734 6 лет назад +2

    What for is pipe in uid = this.afAuth.authState.pipe ???

  • @poojahandigund145
    @poojahandigund145 6 лет назад

    This video really helped me to start with firebase authentication !! thanks a tonnn

  • @shishgeor
    @shishgeor 5 лет назад +1

    Didnt know Beric Dondarion does angular tutorials

  • @ChocoNut-09
    @ChocoNut-09 6 лет назад

    Hello..
    I was following the video but i got some errors from the auth Service.
    Thanks in advance.. :)
    I got confused 15:30
    ERROR in src/app/service/userservice.service.ts(23,35): error TS1109: Expression expected.
    src/app/service/userservice.service.ts(23,37): error TS1068: Unexpected token. A constructor, method, accessor, or property was expected.
    src/app/service/userservice.service.ts(35,23): error TS1005: ',' expected.
    src/app/service/userservice.service.ts(35,29): error TS1005: ',' expected.
    src/app/service/userservice.service.ts(35,48): error TS1005: ';' expected.
    src/app/service/userservice.service.ts(38,11): error TS1005: ';' expected.
    src/app/service/userservice.service.ts(42,12): error TS1005: ';' expected.
    src/app/service/userservice.service.ts(46,1): error TS1128: Declaration or statement expected.
    ==============
    import { Injectable } from '@angular/core';
    import {Observable, of as observableOf,} from 'rxjs'
    import { AngularFireAuth } from '@angular/fire/auth';
    import { map, switchMap } from 'rxjs/operators';
    import { auth } from 'firebase';
    @Injectable({
    providedIn: 'root'
    })
    export class UserserviceService {
    uid = this.afAuth.authState.pipe(
    map(authState => {
    if(!authState) {
    return null;
    } else {
    return authState.uid;
    }
    })
    );
    isAdmin = Observable = this.uid.pipe(
    switchMap(uid => {
    if(!uid) {
    return observableOf(false);
    } else {
    return this.db.object('/admin/' + uid).valueChanges();
    }
    })
    );
    constructor(private afAuth: AngularFireAuth) { }
    login() {
    this.afAuth.auth.signInWithPopup(new auth.GoogleAuthProvider());
    }
    logout() {
    this.afAuth.auth.signOut();
    }
    }

  • @jesselima_dev
    @jesselima_dev 6 лет назад

    Great video! Thanks!

  • @rituhemnani8399
    @rituhemnani8399 5 лет назад

    yarn add angularfire2 firebase is not recognized as an internal or external command

  • @deepakmarneni2110
    @deepakmarneni2110 6 лет назад

    Very nice . Thank you so much. But how data reflecting from firebase without page refresh 🤔

    • @DigitalFluency
      @DigitalFluency  6 лет назад

      The AngularFireDatabase.db.object(path).valueChanges() call returns an observable that emits every time the value changes. It maintains a connection via web socket.

  • @digambersingh555
    @digambersingh555 6 лет назад

    Really helpful, thanks!

  • @Aaron.Aguilar
    @Aaron.Aguilar 5 лет назад

    Hi can you do a video on angular with cordova and firebase auth

  • @CafeRei
    @CafeRei 6 лет назад

    wow, amazing \o/ thank you.

  • @daniellaerachannel
    @daniellaerachannel 6 лет назад

    great!

  • @stockiten3369
    @stockiten3369 5 лет назад

    Thanks for the video please check these 2 projects
    Material Design: github.com/AnthonyNahas/ngx-auth-firebaseui
    Bootstrap: github.com/firebaseui/ng-bootstrap

  • @davidlutta2503
    @davidlutta2503 6 лет назад

    Thank You soo much !!

  • @pradeepam9426
    @pradeepam9426 5 лет назад

    can i get the code

  • @afrikanking4022
    @afrikanking4022 4 года назад

    This Video is irrelevant in 2020