dwyl / learn-flutter

🦋 Learn how to use Flutter to Build Cross-platform Native Mobile Apps
https://flutter.dev
GNU General Public License v2.0
73 stars 8 forks source link

New Repository Google Sign In with Flutter #22

Closed miguelmartins17 closed 1 year ago

miguelmartins17 commented 4 years ago

We should create another repository to explain how to do the Sign In with Google using Flutter (Without using Firebase). It would be good to create a tutorial on this since the topic of Sign In has been addressed many times without using Firebase.

nelsonic commented 4 years ago

@miguelmartins17 this could be relevant after https://github.com/dwyl/flutter-todo-list-tutorial/issues/2 👍 (Google Sign In is not required for the Todo List Tutorial)

nelsonic commented 4 years ago

Longer answer ...

I've just logged into the Figma desktop app via what I am 100% sure was a WebView.

When I clicked the login button in the Native Desktop App:

figma-desktop-login-buton

figma-desktop-instructions

it opens a Web Browser: (so the Auth is NOT implemented in the Native App)

figma-web-view-login

Click on "Log in with Gogle" image

Still in a Web Browser: image

After I authenticated with my Google Account this is what I see: image

I have to click a Button "Open Desktop App" to re-directed back to the desktop app.

An alert appears asking me to confirm that I want to Open Figma.app image

Now I am logged in and can see my wireframe in the Native Desktop App. image

So I know that it's possible to use our Elixir Auth Google (Server-side Auth) and redirect back to a Flutter App. This is 100% how we are going to implement Auth in our Native App. We do not need to re-invent Auth in Dart. If you don't understand how this works behind the scenes, don't worry about it! I will write the code including tests and detailed documentation so everyone understands.

Please focus on the Flutter Todo List Tutorial Task dwyl/flutter-todo-list-tutorial#2 We need a comprehensive Flutter Todo List Tutorial that a complete beginner can understand and learn from so that 100+ @dwylers can learn how to use Flutter. Until the Flutter Todo List Tutorial is complete (without any authentication), we don't need to think about Auth in a Flutter App. We will continue building the Phoenix app: https://github.com/dwyl/app-mvp-phoenix Which will become the Realtime API used by the Native App (when we build it...)

Hope that answers your question or at least directs your focus back to the task. 👍

miguelmartins17 commented 4 years ago

I remain focused on learning how to make a real tutorial with everything necessary to pass all the knowledge acquired about Flutter. I just thought it would be necessary to learn git and how to really use Github, in order to be more productive. I continue to use the tutorials and documents in dwyl/start-here to deepen my knowledge and make my experience with Git easier.

Even following the Tutorial done in Javascript there are still some doubts about how to proceed to make a useful tutorial so that everyone can really learn Flutter without doubt. 😕

nelsonic commented 4 years ago

@miguelmartins17 learning Git/GitHub is indeed required for doing most dev work. :octocat: (that's why it's listed in the How? of "start-here") 👍 Please continue to ask questions in the specific repositories when you have doubts. ❓ The way to proceed is to imitate the existing Javascript Todo List Tutorial.

"Imitation is not just the sincerest form of flattery - it's the sincerest form of learning." ~ George Bernard Shaw

Follow the checklist in dwyl/flutter-todo-list-tutorial#2, build the app and document every step along the way, the same way that I have shown the Javascript Todo List Tutorial.

The most difficult part might be writing automated tests which you have less experience with. (but that's the whole point of meticulously following the Javascript Todo List Tutorial which shows TDD)

Thankfully there are a few really good videos on the Flutter YT channel for testing. e.g:

image https://youtu.be/bj-oMYyLZEY

But if you reach an impassable obstacle (or something that you feel is impossible to understand/achieve), please leave a comment in the issue (or open a new one) immediately so that we can help you overcome it. There are no immovable objects that cannot be overcome when you are an unstoppable force. Your biggest "super power" as a Developer is not coding, it's communication! 💡