Firebase Google Sign-In With Jetpack Compose & Clean Architecture - Android Studio Tutorial

Поделиться
HTML-код
  • Опубликовано: 23 ноя 2024
  • In this video you'll learn how you learn how you can implement Google Sign-In with a Firebase backend in your Kotlin Android app.
    ⭐ Claim the limited 30% easter discount with EASTER30 during checkout ⭐
    pl-coding.com/...
    💻 Let me be your mentor and become an industry-ready Android developer in 10 weeks:
    pl-coding.com/...
    🎓Become an industry-ready developer in the Mobile Dev Campus:
    pl-coding.com/...
    🎁 Get my FREE 4.5h course "The Best Practice Guide to Android Architecture":
    pl-coding.com/...
    Read our weekly Android blog:
    pl-coding.com/...
    Join this channel to get access to perks:
    / @philipplackner
    Get the source code for this video here:
    github.com/phi...
    Join my Discord server:
    / discord
    Regular programming advice on my Instagram page: / _philipplackner_
    Checkout my GitHub: github.com/phi...
    You like my free content? Here you can buy me a coffee:
    www.buymeacoff...

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

  • @kintanpatel6002
    @kintanpatel6002 6 месяцев назад +39

    Some method are deprecated and tell us to use Credential Manager, can we have updated video on Credential Manager?

  • @adityagarud861
    @adityagarud861 Год назад +63

    This guy on RUclips is a life-saver.

  • @SpaceGuideHub
    @SpaceGuideHub Год назад +1

    Your assistance has significantly propelled me towards the launch date, particularly in figuring out Firebase Google Sign-In with Jetpack Compose, implying that I might very well invest in your CI/CD course.

  • @Joel-if2bg
    @Joel-if2bg 9 месяцев назад +5

    For newer verisons of Android Studio (>Flamingo) you need to CHECK the box for "Configure all Gradle tasks during Gradle Sync (this can make Gradle Sync slower)", then Sync Project with Gradle Files

  • @kylewhynott6146
    @kylewhynott6146 7 месяцев назад

    Thanks for the tutorial! I had to build something out more advanced for a project I'm working on, but it was a great tutorial for understanding how to do this with Kotlin and Jetpack Compose. Last time I wrote a major application it was still in Java with Activities, Fragments, and XML Layouts. Love all your videos.

  • @blaupunkt1221
    @blaupunkt1221 6 месяцев назад +6

    Hi Philipp! The latest 21.1.0 version of "com.google.android.gms:play-services-auth" deprecates most of your code. Apparently we are supposed to use the Jetpack CredentialManager instead now. Could you make a video about Firebase Google Sign-In using the CredentialManager? I had some difficulties with it. Thank you!

  • @pasdeal
    @pasdeal 10 месяцев назад +9

    Im running Android Studio Giraffe | 2022.3.1 Patch 2 and to get the signingReport option to show at 6:37 you now need to CHECK the box "Configure all Gradle tasks during Gradle Sync" under the Experimental tab and then sync your project. Thanks for the guide 🥰

    • @supersanta4059
      @supersanta4059 5 месяцев назад

      OMG mate, you saved me right there. Thank you sooo much for that.

    • @user-Farooqzx
      @user-Farooqzx 4 месяца назад

      Thank you

  • @cristiancelis3410
    @cristiancelis3410 4 месяца назад +1

    After watching many videos on how to connect firebase to kotlin with compose, u have saved me :D thx

  • @androidkotlin-6234
    @androidkotlin-6234 Год назад +1

    Do you know what? I'm developing my application, and just open youtobe for find how to auth with google firebase, and saw your video!
    You are amazing, white bro!

  • @victorsokoluik4573
    @victorsokoluik4573 9 месяцев назад

    Thanks, Philipp! Yep, it took a lot of time to adapt your type of navigation to my app, but I did it, and now everything works as expected.

  • @johnpunzak8916
    @johnpunzak8916 Год назад +6

    Suggestion for a new video:. Could you take sign in further and make leaderboards for games? Google did not create a Kotlin version of their leaderboards yet. It would be great to see that. And thank you for your wonderful and amazing videos!!!😊

  • @chiragdhunna990
    @chiragdhunna990 Год назад +7

    Great video video, do make more tutorials like this it will definitely help the community grow!!

  • @eugenewainaina5626
    @eugenewainaina5626 7 месяцев назад

    I like how he blurred the project support email then in the confirmation part it was plain visible 😅 great video though, this is just what I needed

  • @BJKarlGeroniml
    @BJKarlGeroniml Год назад +4

    Please create biometric authentication using jetpack compose next. I really need it.

  • @johnshepard1267
    @johnshepard1267 Год назад +3

    What if we have our own backend and auth system but we want to add a "quick" authorization/registration with Google - can we use the same approach? Will it be possible to somehow map the data of the google account to our account model and save on our servers or create an account with them? Cause I think we would want to also somehow manage users who registered with Google etc?

  • @chips056
    @chips056 Год назад +7

    Great video, you never disappoint! Thank you for this one 😊

  • @TheZaurHasanov
    @TheZaurHasanov Год назад +3

    Omg you came back to Firebase again 😍 Thanks so much

  • @4ytonly
    @4ytonly Год назад +4

    Is there any difference about fetching SHA in debug vs release versions of app???

  • @germenwong
    @germenwong Год назад +1

    As always, wonderful and practical brother. You are really great and have taught me a lot. Please continue to create Compose, integrate Firebase, and Google's

  • @mklmk-vjhbj
    @mklmk-vjhbj 7 месяцев назад +4

    'beginSignIn(BeginSignInRequest): Task' is deprecated. Deprecated in Java 💀💀💀

  • @brianblain3483
    @brianblain3483 Год назад +1

    Heads up! When selecting your email for google auth you covered it up but then at 8:22 you go back to the screen and your email is front and center

    • @arthurdamous
      @arthurdamous Год назад

      Yeah, i've noticed too. Hope no one tries to scam

  • @matteoZattera
    @matteoZattera 6 месяцев назад +2

    12:12 BeginSignInRequest is now deprecated, we have to use Credential Manager instead

  • @meetsoni1938
    @meetsoni1938 Год назад +1

    Thank you so much Philip.Your efforts are really Appreciated 🎉❤❤

  • @falcon1422
    @falcon1422 Год назад

    OMG how much i wish you posted this video a week ago😭😭😭

  • @matteoZattera
    @matteoZattera 6 месяцев назад +1

    Can you please make a video using Credential Manager APIs instead of One tap APIs (deprecated)?

  • @shashankkumar7958
    @shashankkumar7958 Год назад +2

    Don't know if there is some issue with the code or the API itself but what I observe is when I cancel the google sign in bootom sheet 3-4 times consecutively, the sheet never appears again. Hey @Philipp can you look into this?

    • @13_adityasharma74
      @13_adityasharma74 Год назад +2

      it's a google play thing. If you cancel the login a few times it won't appear again for 24 hours or if it was triggered in an emulator u can just clear the google play data

  • @eduardoruesta5180
    @eduardoruesta5180 7 месяцев назад

    Cool!! what could be the difference if we want to do this example in a Compose Multiplatform project?

  • @Tsukikof
    @Tsukikof 7 месяцев назад

    Great job! Thanks a lot, it works perfectly. Can you make firebase sign in with email password also ?

  • @hussein9577
    @hussein9577 Год назад +5

    Great content, just as always

  • @KeringKirwa
    @KeringKirwa 9 месяцев назад

    Hello sir , i have been following your android tutorials for long now and am grateful. I would like to ask something however , what is the difference between web client id and Server key with regards to this project ?

  • @Leon-un2ii
    @Leon-un2ii Год назад +1

    Please make an UI lock screen with a PIN storage like many apps use it. Threema, Telegram, Signal etc. Thanks.

  • @kirwakelvinkering3122
    @kirwakelvinkering3122 Год назад

    Thank you so much for this Philip , ever grateful .

  • @Adam0001
    @Adam0001 Год назад +1

    I love it 😍
    Thanks Mr.Philipp

  • @33t00p
    @33t00p Год назад

    Philipp, thanks for another awesome tutorial.
    I'm just wondering about LoginScreen always hanging there in the backStack as long as user does not log out.
    I haven't tried, but if I will want to pop the Backstack, I will always have to popBackStack(ScreenAfterLogin, inclusive=false)
    Otherwise when we get to LoginScreen, auth request is send to Firebase.
    So there is always this first (LoginScreen) in the backStack.
    Maybe it's better to put LoginScreen before calling AppComposable ?

  • @xanroid
    @xanroid 5 месяцев назад

    I now have thousands of users in my Firebase database who are authenticated using their Firebase Google Sign-in UID. Since this method is deprecated, how should we migrate to Credential Manager in this case while we keep the current users ids?

  • @spookyhades6231
    @spookyhades6231 Год назад

    Wow thanks a lot ... Idk how you manage to do it but every single time I just need help on a topic it just appears in a couple of days 😂

  • @universe8989
    @universe8989 Год назад +1

    Oh my god I love your videos so much, keep making videos pls

  • @Iraskate
    @Iraskate Год назад

    Great tutorial! One issue though, I am trying to save the user's email in the UserData class, but it returns null. Why is that?

  • @aissamelboudi1494
    @aissamelboudi1494 Год назад

    Hello philipp thank for all those videos, can u please lean us how control music in notifications pannel like spotify

  • @karthikeyan8670
    @karthikeyan8670 6 месяцев назад

    I have tried your code in my android Studio, but error is showing like this
    CompositionLocal LocalLifecycleOwner not present

  • @davidrichardroca5899
    @davidrichardroca5899 11 месяцев назад

    Really Thanks for this Great Tutorial. Can you do an other Tutorial of using this authentication to call an Google API like Photos by exemple please. With the Google Dev console settings Pleaaasseee 😊

  • @enriqif
    @enriqif Год назад

    Great video Philipp!! I have a problem with the functionality.. in the emulator works perfect but I my physic device, the bottom popup doesn't show... Did this happen to anyone?

  • @dogu0101
    @dogu0101 11 месяцев назад

    Hi Philipp. Do you have any content to show how to do it for twitter ?

  • @chiragredij1734
    @chiragredij1734 Год назад

    Hey philipp... So I used Compose and Dagger for it and it works completely fine but there is one issue!! I cant get it to display profile picture which is set... Im using FirebaseUser data class instead of custom class. Any idea why this might be happening?

  • @il_benza
    @il_benza Год назад +1

    Hei man, what is the "plugin theme" that you are using for your Android Studio?

    • @stijndcl
      @stijndcl Год назад +2

      You can see his theme at 6:16

  • @HiltModuleImp
    @HiltModuleImp Год назад

    Lol, just got a task to do the same. Right in time))) Thx a lot Philipp

  • @sijanneupane
    @sijanneupane Год назад

    not now!
    will be needing this next week!

  • @pico6051
    @pico6051 Год назад

    It doesn't look "Clean" putting so much logic in the MainActivity, is this really the best way to achieve it?

  • @vishnupriya9437
    @vishnupriya9437 9 месяцев назад

    Hi I have wordpress website I converted using android studio. Everything works fine except the Google login also wordpress signup. Can please help on this. Pls add video on this

  • @tundedon
    @tundedon Год назад +1

    Just in time 🙏🏾🙏🏾

  • @wcman007
    @wcman007 5 месяцев назад +1

    It's depricated please make a tutorial on the new way to sign in with google

  • @osisuper98
    @osisuper98 Год назад

    There is so much we writing outside the composable screens themselves now 🤔. Shit keeps changing.

  • @kyleangelogonzales3989
    @kyleangelogonzales3989 Год назад +6

    Hey Philipp! Love your videos!
    I'm new to MVVM and Compose. Ive heard that it's not good to use context in viewModels so I would like to learn how to work around these scenarios. I also read that we should avoid using the AndroidViewModel class as it defeats the purpose of having a ViewModel in the first place.
    Could you make a video teaching us how to properly separate Android specific code from ViewModel's with MVVM and CLEAN practices?
    Given that a lot of the business logic lives in the ViewModel, how can we:
    1. Use android resources
    2. Make an object that requires an (activity?) context in response to a button click event
    3. Get permissions from button clicks ? With compose and MVVM?
    4. Launching an intent when a button is clicked
    I'm new to all of this, so a tutorial on this would really help me write cleaner and more robust code!

    • @MindBuilders
      @MindBuilders Год назад

      There's no problem using application context in the ViewModel. The reason why they say not to use context in ViewModels is because you don't want to leak a VIEW context. Application context exists through the duration of the app.
      That's what the purpose of the AndroidViewModel is, it takes in an Application so you can rely on Application context.

  • @sheikhbilalahmad2689
    @sheikhbilalahmad2689 8 месяцев назад

    Thank you! Philipp the goat

  • @utusan_bapak
    @utusan_bapak Год назад

    How to periodically start workmanager to monitor the expired state? (Assumed successfully logged in) and the work manager is bound to activity level state

  • @javimardeveloper
    @javimardeveloper Год назад

    Awesome video Phillip, will this be enough auth in order to use google drive API?

  • @cse9193
    @cse9193 6 месяцев назад

    I am using mvi pattern in my project. Is it correct to send the userData object as a parameter to the profile screen?

  • @AnandFromDelhi
    @AnandFromDelhi Год назад

    next video I would like to see would be Notes app using firebase

  • @imsosorrybro
    @imsosorrybro 9 месяцев назад

    damn! thanks for content but why did you do that without layotu? I have an issue but cannot solve it because of it :(

  • @balusekhar
    @balusekhar Год назад

    Need a tutorial on retrofit with jetpack compose

  • @chiragredij1734
    @chiragredij1734 Год назад

    Why not use Destinations Compose? Is it not mainstream yet?

  • @dzikryhabibie6071
    @dzikryhabibie6071 Год назад

    Hello, i try to use the version control to build the app, but my application has a problem, the Google account pop up doesn't appear, what happened? What should I fix, can anyone help me?

  • @omarcode6245
    @omarcode6245 Год назад +1

    Hola phillip como estas gran tutorial, porque no manejaste la logica en el viewmodel como en todos tus videos

  • @IlyaProk
    @IlyaProk Год назад

    what to do if the registration works on the emulator, but not on the protection of the phone. Yes, I gave access to the Internet in manifest . help pleas

  • @arthurmsiska3800
    @arthurmsiska3800 10 месяцев назад

    Could you do same OAuth sign in but with Supabase?

  • @walterdawidretzer465
    @walterdawidretzer465 Год назад

    Great Video, its helps me a lot!!!!!!!!!!

  • @slyene6202
    @slyene6202 7 месяцев назад

    Hi! What's the difference between LaunchedEffect key1 = true and key1 = Unit?

  • @stijndcl
    @stijndcl Год назад

    How does all the coroutine logic in the MainActivity at the end translate to the compose-destinations package for navigation? Are you supposed to just run all of those in your LoginScreen composable instead?

    • @pico6051
      @pico6051 Год назад

      Found anything useful?

  • @mr.chouhan_07
    @mr.chouhan_07 Год назад

    brother can u make video also for Facebook Sign-In

  • @universal1755
    @universal1755 Год назад

    Thanks, It helped alot. ❤

  • @sanjaybhatikar
    @sanjaybhatikar Год назад

    Didn't work with some cryptic error about missing feature in gms.

  • @AmalShiwantha-n7b
    @AmalShiwantha-n7b 5 месяцев назад

    Can you share how to call Facebook login in compose

  • @carlosmartinezsuarez3541
    @carlosmartinezsuarez3541 Год назад

    Hi! I can´t use the GoogleAuthUiClient() :( whyyy? Now is deprecated?

  • @krishnamadke9085
    @krishnamadke9085 Год назад

    very nice explaination !

  • @serlok4688
    @serlok4688 Год назад

    Thank you Philip

  • @pounes_ir
    @pounes_ir Месяц назад

    thank you 💕💕💕💕💕💕

  • @thebhagwabilla
    @thebhagwabilla 3 месяца назад

    i thought of integrating google signin but its too lengthy

  • @arthurkopytin9177
    @arthurkopytin9177 Год назад +1

    How to implement it without Compose?

  • @P_Atticus
    @P_Atticus Год назад

    Can you implement it, but without jetpack?

  • @prarooptrivedi
    @prarooptrivedi 11 месяцев назад

    can you provide same video for facebook sign in

  • @VasilisBitloops
    @VasilisBitloops Год назад +1

    Wouldn't it make sense to use an AuthenticationProvider interface with a Firebase concretion to be able to a) mock the provider and b) switch the provider to another one in the future?

  • @nicedoodly6392
    @nicedoodly6392 2 месяца назад

    Thanks

  • @SuperSapna007
    @SuperSapna007 8 месяцев назад

    I tried with your code its not working and not throwing any error. :(

  • @kinohometv1985
    @kinohometv1985 Год назад

    Great, thanks 👍👍

  • @thecoderui
    @thecoderui Год назад

    How did you know that we are working these days to add this feature in our new app? 🤔 Impossible 😂

  • @BlackSpaceCreation
    @BlackSpaceCreation 7 месяцев назад

    Anyone else have problems with implementing this? I dont get the google sign in pop up

  • @mdevelo
    @mdevelo Год назад

    Has anyone got this error "Caller not whitelisted to call this api"? I tried fixing it in so many ways but it didn't work. If someone has solution, please help me. Thank you!

  • @superkobke
    @superkobke 11 месяцев назад +1

    Damn, my SignIn button is not working!!!!

    • @ConspiracyCraftersStudio
      @ConspiracyCraftersStudio 8 месяцев назад

      you probably did onClick = {onSignInClick} and you should onClick = onSignInClick

  • @JackSparrow-xd1vp
    @JackSparrow-xd1vp Год назад

    Can i get your course in udemy?

  • @John-qt6qk
    @John-qt6qk Год назад

    Thanks

  • @diaahelmy6889
    @diaahelmy6889 Год назад

    hi can you make app change location

  • @meetsoni1938
    @meetsoni1938 Год назад

    Hey I am getting this error "unresolved reference: lifecycleScope"

    • @moisesvalera3597
      @moisesvalera3597 Год назад +2

      Use val coroutineScope = rememberCoroutineScope() instead

    • @meetsoni1938
      @meetsoni1938 Год назад

      @@moisesvalera3597 okay thanks 👍

  • @jopadjr
    @jopadjr Год назад

    177th...Thanks Philipp. I'm looking at the bundle price and it is currently 359,00€. Is this in Euro?

    • @stijndcl
      @stijndcl Год назад

      There's a € sign so is that really a question?

    • @jopadjr
      @jopadjr Год назад

      @@stijndcl it is a question. Need to double check as there is a comma, Im not familiar with this currency. It might be in thousands. That is why Im asking

    • @stijndcl
      @stijndcl Год назад

      @@jopadjr if it would be thousands then there would be three zeroes, not two.

    • @jopadjr
      @jopadjr Год назад

      @@stijndcl Thanks. I actually checked it in the Australian dollar equivalent. And that comma is confusing as we only used it for thousands. No harm in asking

  • @thangnguyen8899
    @thangnguyen8899 11 месяцев назад

    Nice

  • @TechSciInfo
    @TechSciInfo 9 месяцев назад

    firebase to android jetpack compose download pdf in app please make video ..

  • @ffggi-qv5ey
    @ffggi-qv5ey Год назад

    Why writing tests is such an abstract concept. Does noone write tests?

  • @ahmadab9666
    @ahmadab9666 Год назад

    Firebase !!? you said from years ago you won't use firebase again :)

  • @Rafa-iy2ng
    @Rafa-iy2ng Год назад

    Why not EASTER100? :)

    • @PhilippLackner
      @PhilippLackner  Год назад

      Don't try this plz

    • @Rafa-iy2ng
      @Rafa-iy2ng Год назад

      @@PhilippLackner It says that someone already used it :( maybe next time...

  • @efrainarreola7002
    @efrainarreola7002 Год назад

    Dagger hilt? 😢😢😢😢

  • @dallasrieck7753
    @dallasrieck7753 4 месяца назад +1

    share, not tutorial😉