This is just awesome !!! please don't stop the GetX series
@tadaspetra4 жыл бұрын
Faisal Al Bahli I don’t know how much else there is to do, but I’ll probably be using it for some projects
@Septix3 жыл бұрын
I usually don't comment but jesus man you are amazing. No BS, filler crap or anything, straight to the point. Also cannot thank you enough for not using a complicated UI so we see what's actually going on.
@tadaspetra3 жыл бұрын
Thank you so much! That is what I aim to do in every video. And for me it also makes it a lot simpler using easy UIs because the logic doesn’t get lost in ther e
@josueorozcoaltamirano71013 жыл бұрын
it would be awesome if you could remake this whole tutorial with the updated information... i'm kind of lost
@vishnuprasadh76924 жыл бұрын
Awesome video. Loved it. Keep up the great work 🔥
@tadaspetra4 жыл бұрын
Thank you so much
@JonAndroide4 жыл бұрын
I don't get the error "AuthController deleted from memory" is for any new update on getX library or something like that?
@lubshadpattarathil2804 жыл бұрын
Perfect and clean
@tadaspetra4 жыл бұрын
Thank you 😊
@deepL02 жыл бұрын
6:37 - 9:05 what is the reason for doing that( I mean extend by GetWidget ). I have never seen this
@TechnoDB2 жыл бұрын
GetWidget allows you to access controller by simply writing the keyword controller else you have to initialize the controller by sth like Get.put or Get.find manually.
@jrheisler4 жыл бұрын
Great, thanks!
@tadaspetra4 жыл бұрын
j heisler thank you. Appreciate it!
@shoiburrahmankhansifat71763 жыл бұрын
Everythings was work fine but yesterday I migrate the Flutter version to the latest one Flutter 2.2 (stable)and dart SDK version to 2.13(stable). After migration, I get an error on the auth_controller file. Rx _user = Rx(); in that line, it says 1 positional argument(s) expected, but 0 found. Any one help me please!😐
@이승현-c2r3 жыл бұрын
@Kyden What does Rxn do? compare to Rx
@이승현-c2r3 жыл бұрын
@Kyden Rxn requires null-safety. gotcha
@이승현-c2r3 жыл бұрын
@Kyden Thanks!
@rodrodrigues1729 Жыл бұрын
Hi there, thanks for this nice video. Two questions, why onAuthStateChanged and not .userChanges()? and why lazyPut?
@poisonels80233 жыл бұрын
Can you update this serie please
@nudgecodes74714 жыл бұрын
Great , did you think before if you want pass an a argument in controller constructor and defined it 'controller' before widget builder not wrap a widget builder with GetX or GetBuilder!
@fedorstepanov37313 жыл бұрын
I really liked getx, but still have one question about the right architecture for that package. Because it can fit to mvc and mvvm, but there are a few pretty uncomfortable moments when you try to build this type of architecture in your app. Is it a nice practice to connect one controller to e.g 2 viems?
@DreamBigEducation3 жыл бұрын
Hii Bro, i run this code but shows error => *1.Too few positional arguments: 1 required, 0 given. Rx _firebaseUser = Rx(); @AuthController. *2. The getter 'documentID' isn't defined for the type 'DocumentSnapshot'. Try importing the library that defines 'documentID', correcting the name to the name of an existing getter, or defining.. @UserModel Please give me a solution Bro..
@__eugene_choi3 жыл бұрын
same problem :(
@viniciusgregorio14123 жыл бұрын
did u figured out the solution for _firebaseUser? I still don't find how to initialize, and I don't know what argument Rx wants.
@DreamBigEducation3 жыл бұрын
@@viniciusgregorio1412 i will send error file(image)..? How to connect you sir..
@yasserharzelli79843 жыл бұрын
@@viniciusgregorio1412 same here , did u figure it out ?
@viniciusgregorio14123 жыл бұрын
@@yasserharzelli7984 yes, call me on discord Skyzitcho#2024
@akhilksugathan3 жыл бұрын
String? get user { return _firebaseUser.value?.email; } User only updates with new user creation not with login, How to solve
@wizzl85134 жыл бұрын
In the documentation it says "The use case [of GetWidget] is very rare, but very specific" but in this app we are using it for every screen. I feel like this is not intended. Correct me if I'm wrong.
@tadaspetra4 жыл бұрын
So at the time of writing this, GetView and GetWidget were identical. Maybe that has changed, or maybe the recommended options is GetView now
@wizzl85134 жыл бұрын
@@tadaspetra Got it, thanks for clarifying.
@Juliapak2 жыл бұрын
fyi just to update everyone: FirebaseUser is now User. And you must instantiate not just Rx firebaseUser... While using a GetxController on a class, and using Rx to get a FirebaseUser , you'll be shown an error, that you are missing a positional argument! Use this instead: Rxn firebaseUser = Rxn();
@wesleybarnes53763 жыл бұрын
Why does the app not log out when you are doing logout() from another screen, I understand the Obx as observing the stream, and reacting to it. Is it not supposed to return Login() when I am down the widget tree, in say "profile" screen. I am coming from a provider mindset where a stream in main.dart use to do this.
@RobertoOrtis4 жыл бұрын
You should do GetX pattern and authentication with bindings and dependencies injection
@tadaspetra4 жыл бұрын
Roberto Ortis ya I've been meaning to take a look at GetX pattern. But do you have an example of authentication with bindings and DI
@RobertoOrtis4 жыл бұрын
@@tadaspetra I am currently working on an example but can't get the authentication controller to run before GetMaterialApp without running into an error where the controller is not found. I followed a tutorial from another KZbinr but he does the authentication through a Splash screen (which I don't like). I can send you the link to the KZbinr videos I just mentioned but it's in spanish. Let me know. I am still working on my own example and will let you know if I get it fixed.
@tadaspetra4 жыл бұрын
Roberto Ortis I probably won't understand it if it's Spanish haha. But yea definetely send me your example if your figure it out 😊
@RobertoOrtis4 жыл бұрын
@@tadaspetra I just got it working. I will let you know when I upload it to github.
@TimKariuki4 жыл бұрын
I have an app where I was using Provider in a stateful login widget. Is there a tutorial for that?
@tadaspetra4 жыл бұрын
I don’t have one exactly for that. But I do have a playlist for provider
@congtoannguyen19403 жыл бұрын
Why do we want our user to be observeable if I doesn't need to appear on the UI and Can you make a verification for the email.
@akhilksugathan3 жыл бұрын
I still didn't understand how the Get.back() works in signup. As of my understanding if the user authstate changes then the obx code will run and it will re-run the root code. Isn't it enough to update the user to the home screen, even he is logged from the signup screen? Please reply.
@sowmyancs3 жыл бұрын
Can we use GetxService for Auth service instead of creating the root widget to redirect the user ?
@chendaoeun83813 жыл бұрын
Dear sir, when I try to do this I got an error " The getter 'email' was called on null. Receiver: null Tried calling: email " and I still cannot fix it. Any help me please. thanks in advance!
@bilalabudan96453 жыл бұрын
is it solved?
@Hypothermia13374 жыл бұрын
For having an initialBinding in my GetMaterialApp, is it possible to place multiple unique controllers inside one binding? Since my project needs like ~15 controllers, which (almost all) need to be loaded at the start of the application and display fetched data in a dashboard-kind-of-home-page.
@tadaspetra4 жыл бұрын
Yes, should definitely be possible. There is nothing stopping you from initializing 10000 controllers in a binding.....except maybe the processor power 😂
@ssn10574 жыл бұрын
please make a video on making shop purchase receipt and pdf printing
@tadaspetra4 жыл бұрын
That’s a very specific thing. But I’ll see if I can add it in somewhere ☺️. Thanks for the suggestion
@ssn10574 жыл бұрын
I didn't expect that u'd be interested! Thanks!
@yomna_mi3 жыл бұрын
It shows me an error " the method bindStream was called on null ?
@viniciusgregorio14123 жыл бұрын
did you figured it out? same here
@yomna_mi3 жыл бұрын
@@viniciusgregorio1412 yeah it had something to do with get version use this version ^3.26.0 it will fix it or take an instance in main function and don't use getx
@viniciusgregorio14123 жыл бұрын
@@yomna_mi tyyyyy
@nijojoseph4 жыл бұрын
I think i saw your new tutorial on youtube the firebase getx Todo App the new version. But now I think it is missing.......
@tadaspetra4 жыл бұрын
I made one on freecodecamp. But it wasn’t using GetX 😊. I promise I haven’t removed anything haha
@darshshah50514 жыл бұрын
Would love to see you make a tutorial for an full fledge expense tracking application!!
@tadaspetra4 жыл бұрын
Good Suggestion! I'll put it on my list. The next two things I want to try is a Flutter website, and then a chat app!
@darshshah50514 жыл бұрын
Wow!!
@shubhammittal97644 жыл бұрын
@@tadaspetra When chat app coming brother? Please use GetX, and more importantly Realtime Database for chat functionality because in real world scenario RTDB is about 5 times cheaper than Firestore for chatting.
@saransundaresanmadhavan8103 жыл бұрын
For Google Sign in , how to hide the login page if a user is already logged in? Can u make a separate video for google sign in too?
@tadaspetra3 жыл бұрын
It should be very similar. Firebase Auth provides the data for what use is authenticated, it doesn't matter whether it's from GoogleSignIn or normal. And in the book club series we added google sign in, so you can take a look there too
@이제영-n5b3 жыл бұрын
hello sir, it was so wonderful and nice tutorial. btw i wonder authcontroller can detect one user per one device???
@FunGuardian4 жыл бұрын
may i know, why you make obx in root.dart
@tadaspetra4 жыл бұрын
FunGuardian so if the authentication state changes it will move you to a different screen 😊
@FunGuardian4 жыл бұрын
@@tadaspetra wow, thx a lot for replying
@tadaspetra4 жыл бұрын
FunGuardian no problem! 😊
@yulkin20024 жыл бұрын
hi Tadas, how would you test this code? I'm really at a loss when it comes to testing GetX controllers
@tadaspetra4 жыл бұрын
It is similar to testing any other state management. You can just load the state in manually, and then run the test relying on that state
@yulkin20024 жыл бұрын
@@tadaspetra I tried that, but getting a missing plugin exception with respect to Firebase Auth, I assume because it's called from inside the controller. I know we must set up Firebase before testing any code that depends on it, haven't yet found any info on how to set up Firebase auth
@tadaspetra4 жыл бұрын
@@yulkin2002 ah yes. Testing shows a lot of architecture problems. I guess the architecture I was showing was not too good haha. Firebase dependencies should be passed into the controller to help with encapsulation. Then you can mock Firebase Auth 😊
@yulkin20024 жыл бұрын
@@tadaspetra ah I see, let me give this a try. thanks :)
@yulkin20024 жыл бұрын
@@tadaspetra on a second thought, since we use stateless widgets, do we really want to initialize Firebase auth in the screen widget code? I would think not, since it will only be used inside the controller. If not inside the widget, what's the appropriate place to initialize auth and pass it into the controller? EDIT: I think the way to go would be bindings? Found this nice example: github.com/jonataslaw/getx/issues/757
@akhilksugathan3 жыл бұрын
For those having problem with e.message , Problem solved by adding "on FirebaseAuthException" before "catch" and converting "e.message" to "e.message.tostring()" Full Code: void createUser(String email, String password) async { try { await _auth .createUserWithEmailAndPassword(email: email, password: password) .then((value) => Get.offAll(Home())); } on FirebaseAuthException catch (e) { Get.snackbar("Error while creating account", e.message.toString(), snackPosition: SnackPosition.BOTTOM); } }
@АлександрИванов-ю8с8г4 жыл бұрын
please make video about binding.
@tadaspetra4 жыл бұрын
Александр Иванов I don't know if there's much more to it then what I covered in "GetX Other Features" video. Is there something else you would like to know about it
@markkevingatchalian43483 жыл бұрын
Hi! Tadas, How can i make this a role base login with 3 types of user [admin,collector,user]? im stuck with this .. Thank you!
@tadaspetra3 жыл бұрын
The authentication service I don’t think you can do that, BUT you usually store more user information in firestore. So you can store what type of user they are and during the login process check that as well, and send them wherever necessary based on that
@markkevingatchalian43483 жыл бұрын
@@tadaspetra I already added role info in firestore but I dont know where to check the role during login I'm just a beginner .. return GetX( initState: (_) async { Get.put(UserController()); }, builder: (_) { if (Get.find().user?.uid != null) { return AdminView(); } else { return LoginView(); } } ); }
@tadaspetra3 жыл бұрын
@@markkevingatchalian4348 Whenever you are calling the authentication, you can check it right after you get authenticated
@thestacksdev3 жыл бұрын
It's so seamless
@elliotjack69994 жыл бұрын
I think the discord link might not be working, invite expired for me anyway, looking forwards to the live streams bit late for me so will need to tune in next morning
@tadaspetra4 жыл бұрын
you are right! Its updated now in the descripition to discord.gg/CPwSezC I didn't know they expired lol
@elliotjack69994 жыл бұрын
@@tadaspetra cheers joined 😁
@aritrachoudhury84094 жыл бұрын
Hi! Can anyone tell me how to use the initState in GetBuilder? class BestDeals extends StatelessWidget { @override Widget build(BuildContext context) { bool isCalled = false; return GetBuilder( init: ProductController(), builder: (_) { if(!isCalled){ _.getBestDeals(); isCalled = true; } return AppBackground( child: _.bestDeals.isNotEmpty ? StaggeredGridView.countBuilder( crossAxisCount: ScreenSize.getWidth(context: context) < 360 ? 1 : 2, crossAxisSpacing: 5.0, mainAxisSpacing: 5.0, itemCount: _.bestDeals.length, padding: EdgeInsets.all(5), shrinkWrap: true, itemBuilder: (BuildContext context, int index) { return ProductCard( productDetails: _.bestDeals[index] ['product_details'], productQuantities: _.bestDeals[index] ['product_quantity'], ); }, staggeredTileBuilder: (int index) => StaggeredTile.fit(1), ) : SpinKitFadingCircle( color: Colors.white, size: 50.0, ), ); } ); } } How to implement this code in a better way?
@mitzukodavis73934 жыл бұрын
first
@evansaddo29654 жыл бұрын
You are doing great but you need to improve your video quality