The repo contains the source code for all the tutorials on the FilledStacks Youtube channel.

Overview

Flutter tutorials

The repo contains the source code for all the written tutorials by Filledstacks.

All Tutorials plus additional snippets and shorter posts can be found on the Official FilledStacks website. Each tutorial's code can be downloaded separately using the "Download Code" button under the Thumbnail images in the Written tutorials linked below.

Buy Me a Coffee at ko-fi.com

Please clone and star this repo to stay up to date on changes.

Packages by FilledStacks

Stacked: A package that helps implement the stacked architecture as shown in this series

SmartFlare: An extension of the already awesome Flare packages that adds interactive to FlareActors with some more functionality.

Responsive Builder: A package that helps you write a readable and maintainable Responsive UI code base. Based on the responsive UI series

** Important **

When you want to run any of the code first run

flutter create .

In the repo to generate the platform projects for the tutorials.

Tutorials

067 - Flutter Slivers Explained [ Video ] [ Source ] [ Written ] - In this tutorial I go over what slivers are, how they work and how to implement your own custom sliver.

066 - Login and Create Account Implementation [ Video ] [ Source ] [ Written ] - This tutorial goes over implementation we'll be using for Login and Create Account functionality.

064 - New Improved Stacked Setup [ Video ] [ Source ] - This tutorial goes over the new and improved stacked setup that includes navigation, dependency registration and the traditional stacked statemanagement.

063 - Firebase Authentication in 5 minutes [ Video ] [ Source ] - In this tutorial we setup the firebase authentication for a flutter app in 5 minutes

062 - Code overview for Firebase Backend [ Video ] - This tutorial goes over the code required to build a scalable firebase backend

061 - Planning a Firebase Backend [ Video ] - In this tutorial we go over a detailed plan for building a scalable backend using Firebase Cloud Functions.

060 - Making Technical decisions [ Video ] - In this tutorial we go over the thinking and reasoning behind making some of the technical decisions required when planning for a large scale product development

059 - Planning a Food Delivery Service [ Video ] - This tutorial goes over the planning for a food delivery product

058 - Bottom Sheet Service | Using Flutter Bottom Sheets without context [ Video ] [ Written ] [ Source ] - This tutorial goes over the usage of the new BottomSheetService in the stacked_services package.

057 - SQLite in Flutter | Migrations and Schema Management [ Video ] [ Written ] - This tutorial goes over the SQLite implementation used in our production applications. It shows the basics of SQLite. The meat of the tutorial comes from the schema management solution we use.

055 - Lottie Splash Screen in Flutter [ Video ] [ Written ] - A tutorial that shows you how to implement an animated splash screen using Lottie and delay the navigation until it's complete.

054 - Flutter Architecture Part 7 - Dialog Service [ Video ] [ Written ] [ Source Code ] - A complete guide to the setup of the basics for a starter stacked architecture project.

053 - Flutter Architecture Part 6 - Bottom Navigation with Stacked [ Video ] [ Written ] [ Source Code ] - A guide to implementing a bottom navigation bar using stacked.

052 - Flutter Architecture Part 5 - How to Mock - Unit Testing [ Video ] [ Written ] [ Source Code ] - A complete guide to mocking in unit testing, how it's used for tests and what they're used for.

051 - Flutter Architecture Part 4 - How to Unit test a Unit Testing intro [ Video ] [ Written ] [ Source Code ] - An intro to unit testing and how to set it up in Flutter.

050 - Flutter Architecture Part 3 - Flutter Services [ Video ] [ Written ] [ Source Code ] - A complete guide on services, service classes, what they are used for and how to use them.

049 - Flutter Architecture Part 2 - Stacked State Management scenarios [ Video ] [ Written ] [ Source Code ] - This tutorial goes over common state management situation encountered in a real world application

048 - Flutter Architecture Part 1 - Stacked, Routing and GetIt setup [ Video ] [ Written ] [ Source Code ] - A complete guide to the setup of the basics for a starter stacked architecture project.

047 - Firebase and Flutter Part 10 - Remote Config [ Video ] [ Written ] - This tutorial goes over remote config and how to manage it in a flutter project.

046 - Firebase and Flutter Part 9 - Dynamic Links in Flutter [ Video ] [ Written ] - This tutorial covers the use of dynamic links in flutter to perform auto routing and deep linking.

045 - Firebase and Flutter Part 8 - Realtime Paginated Data using Firestore [ Video ] [ Written ] - This tutorial shows the implementation of getting real time firebase data when impelementing an infinte scrolling view.

044 - Firebase and Flutter Part 7 - Analytics [ Video ] [ Written ] - This tutorial shows you how to add analytics into your Flutter app for live monitoring of your users.

043 - Firebase and Flutter Part 6 - Push Notifications using Cloud Messaging [ Video ] [ Written ] - This tutorial goes over my implementation of Push Notification in Flutter using Firebase Cloud Messaging.

042 - Firebase and Flutter - Part 5 - Firebase Cloud Storage [Video ] [ Written ] - In this tutorial we go over the implementation details of using Firebase Cloud Storage inside a Flutter application.

041 - Firebase and Flutter - Part 4 - Firestore Security Rules [ Video ] [ Written ] - This tutorial covers the implementation of Firestore security rules and how to test them.

040 - Firebase and Flutter - Part 3 - CRUD using Firestore [ Video ] [ Written ] - This tutorial goes over the CRUD implementation using Firestore. We Create documents, Read the collection, Delete documents and Update existing documents data through Flutter.

039 - Firebase and Flutter - Part 2 - Custom Startup Logic and User Profiles [ Video ] [ Written ] - This tutorial goes over the process of making sure we startup on the correct view and the logic behind adding a custom user profile.

038 - Firebase and Flutter - Part 1 - Basic Authentication [ Video ] [ Written ] - This tutorial covers the setup of a firebase project and the basic functionality to perform a login / sign up using Firebase email authentication.

037 - Flutter Web Development - Part 6 - Advanced URL navigation [ Video ] [ Written ] - In this video we cover URL navigation in Flutter Web that allows us to navigation within a template and pass in query parameters.

036 - Flutter Web Development - Part 5 - Hover Effects [ Video ] [ Written ] - This video goes over how to add hover effects into Flutter Web.

035 - Flutter Web Development - Part 4 - State and API integration [ Video ] [ Written ] - In this video we integrate the provider_architecture package and create a simple API class to fetch our data.

034 - Flutter Web Development - Part 3 - Template Layouts [ Video ] [ Written ] - This tutorial contains the code for a Flutter Template Layout for Web Development.

033 - Flutter Web Development - Part 2 - Responsive UI [ Video ] [ Written ] - This guide goes over adding responsiveness to your Flutter web UI

032 - Flutter Web Development - Part 1 [ Video ] [ Written ] - In this tutorial we create a Flutter web app, build a basic UI and deploy it to firestore.

031 - Flutter Responsive UI - Part 3 [ Video ] [ Written ] - This tutorial goes over the process of adding Provider on top of an existing Responsive UI framework for state management.

030 - Flutter Responsive UI - Part 2 [ Video ] [ Written ] - This tutorial / guide goes over how you can build a responsive UI architecture to allow for a maintainable and manageable multi platform code base.

029 - Flutter Responsive UI - Part 1 [ Video ] [ Written ] - This tutorial goes over the process of building a base widget that provides us with all the information to build a responsive UI.

028 - Flutter Continuous Scroll [ Video ] [ Written ] - This tutorial goes over how to create a continuous scrolling list in Flutter using index numbers and not the scroll controller.

027 - Flutter Location Service [ Video ] [ Written ] - This tutorial covers the should be common task of wrapping a set of functionality within a service. We build a location service that provides continuous updates using the Location package.

026 - Flutter stream basics. Absolute basics [ Video ] [ Written ] - This is a short tutorial that covers the creation, usage and management of streams. I also cover how to manually create Streams using async* functionality.

025 - Flutter navigation without BuildContext | Navigation Service [ Video ] [ Written ] - This tutorial covers the creation of a Navigation Service to move your navigation logic out of your UI files into the business logic files.

024 - Abstraction in Flutter Pt2 | Better unit tests using Abstraction [ Video ] [ Written ] - In this tutorial we go over how using Abstraction can make your unit tests better.

023 - Abstraction In Flutter Pt1 | How it can save hours of development time [ Video ] [ Written ] - This tutorial is part one of the abstraction series that will cover the benefits of abstraction in practical use cases. In this one we look at how using a second implementation of an interface that returns fake data can speed up your application development.

022 - Build a Lifecycle manager for Background behaviour in Flutter [ Video ] [ Written ] - In this tutorial I go over how to build and hook up a LifeCycle manager to the Flutter AppLifeCycle. We use that to start and stop services within our architecture when the app enters a background state or come back to the foreground.

021 - Build an architecture for your dialog management in Flutter [ Video ] [ Written ] - This tutorial guides you on how to create a dialog manager in Flutter that allows you to show and access information from dialogs from your business logic.

020 - A Guide to using Futures [ Video ] [ Written ] - This tutorial goes over the functionality provided by Futures and how to use it.

019 - Flutter animation Guide | Deep Dive | Flutter Hooks and Flutter Sequence Builder [ Written ] [ Video ] - This tutorial goes over every way you can organise your animation code using the provided flutter functionality. Then we go to Flutter hooks to help reduce the code and we look at the sequence builder to create some combined animations.

018 - Bottom Sheet Guide in Flutter [ Written ] [ Video ] - This tutorial goes over everything you need to know to effectively make use of the BottomSheet in your app.

017 - Better Logging in Flutter [ Written - Effective Logging ] [ Written - Setup Guide ] [ Video ] - This set of tutorials cover logging in Flutter. It shows you how to set it up, and it also gives you guidelines on where to use it and what to log when using it.

016 - Flutter Navigation using Named Routing [ Written ] [ Video ] - This tutorial guides you through everything you need to know about navigation in Flutter using named routing.

015 - Animated SplashScreen with Flare [ Written ] [ Video ] - This tutorial shows how to setup your splash following up with a nice intro animation built in Flare.

014 - Flutter Provider V3 Architecture using ProxyProvider [ Written ] [ Video ] - In this tutorial we implement a previously built app using Provider only and show how an architecture with dependency injection can be setup using the ProxyProvider.

013 - Flutter Dependency Injection for Beginners [ Written ] [ Video ] - In this tutorial I explain what dependency injection is in plain english and show three ways of implementing it in Flutter.

012 - Flutter Provider - Sharing Data Between Models using Services [ Written ] [ Video ] - In this tutorial I expand on my previous tutorial showing how you share data between models using services.

011 - Network Sensitive UI in Flutter using Provider and Connectivity [ Written ] [ Video ] - In this tutorial I create a network sensitive UI that shows different states based on the status of your connection.

010 - Flutter Architecture - A complete guide to Provider [ Written ] [ Video ] - In this tutorial / guide I cover the complete architecture to build a production app using the provider package for state management.

009 - Build a User Feedback app using Flutter and Firebase [ Written ] [ Video ] - In this tutorial I guide you through the steps to implement a real time user feedback app using firebase, flutter and the ScopedModel architecture.

008 - Building a Realtime stats monitor using Flutter and Firebase [ Written ] [ Video ] - In this tutorial I go over the steps for implementing a real time stats monitor for AppSkeletons

007 - Flutter Architecture - A complete guide to the ScopedModel architecture [ Written ] [ Video ] [ AppSkeletons ]- In this tutorial we'll lay the foundation to develop an application using Flutter and ScopedModel that's easy to maintain and extend.

006 - Flutter + (Smart)Flare - Building a Gooey side menu [ Source ] [ Video ] [ Animation ] [ Written (code only) ] - In this tutorial I go over the process of building a slide out menu in Flare. Then importing into Flutter and using SmartFlare to add some interactive functionality to it.

005 - Overflown Stacks - A Guide to basic navigation in Flutter using Navigator [ Video ] [ Written ] [ Source ] - This repo contains an implementation of basic navigation using the code snippets defined in the guide.

004 - Flutter Foundation - Handling Async behaviour - From setState to Architecture [ Written ] [ Source ] [ Video ] - In this tutorial I show how you to handle async functionality and all it's states starting with setState and working up to a reactive architecture using streams.

003 - Using SmartFlare for Flare animation interactions [ Video ] [ Written ] [ Package ] [ Source ] - In this tutorial I introduce my SmartFlare package that wraps normal FlareActors into a more interactable widget.

002 - Smarter Flare Animations in Flutter - An Experiment [ Video ] [ Written ] [ Source ] - In this tutorial we look at how to reduce animation boiler plate code in Flutter using some basic calculations and the Awesome Flare.

001 - Building a UI in Flutter - TikTok example: [ Video ] [ Written P1 ] [Written P2] [Source] - In this tutorial we break down the UI into Flutter Widgets, complete our layout and then tweak to get our final design to match our screenshots.

Comments
  • 045 After removing all documents it's not updating in the UI

    045 After removing all documents it's not updating in the UI

    This code only can update the UI if the collection isn't empty

    if (updatedMessages != null && updatedMessages.length > 0) {
            _chatMessages = updatedMessages;
            notifyListeners();
          }
    
    opened by dsourav 15
  • Unhandled Exception: Once you have called dispose() it can no longer be used.

    Unhandled Exception: Once you have called dispose() it can no longer be used.

    Hi,

    Im getting the following error messages after implementing the CRUD code:

    [ERROR:flutter/lib/ui/ui_dart_state.cc(157)] Unhandled Exception: A HomeViewModel was used after being disposed. E/flutter (13683): Once you have called dispose() on a HomeViewModel, it can no longer be used.

    Do you have any suggestions on how to solve this?

    Thanks!

    opened by niklas-b 15
  • Dispose issue in provider architecture part 2

    Dispose issue in provider architecture part 2

    Hi,

    In provider architecture pt2 there is an issue when views and widgets derived from BaseView are disposed.

    To reproduce: Launch the app, login to fetch and show posts on the homeview then go back to login screen. You will see the FlutterError exception in the debug console content thrown by ChangeNotifier.

    I/flutter (30244): ══╡ EXCEPTION CAUGHT BY WIDGETS LIBRARY ╞═══════════════════════════════════════════════════════════
    
    I/flutter (30244): The following assertion was thrown while finalizing the widget tree:
    
    I/flutter (30244): A HomeModel was used after being disposed.
    
    I/flutter (30244): Once you have called dispose() on a HomeModel, it can no longer be used.
    
    I/flutter (30244):
    
    I/flutter (30244): When the exception was thrown, this was the stack:
    
    I/flutter (30244): #0      ChangeNotifier._debugAssertNotDisposed.<anonymous closure> 
    
    I/flutter (30244): #1      ChangeNotifier._debugAssertNotDisposed 
    
    I/flutter (30244): #2      ChangeNotifier.dispose 
    
    I/flutter (30244): #3      _BaseViewState.dispose 
    
    I/flutter (30244): #4      StatefulElement.unmount 
    
    I/flutter (30244): #5      _InactiveElements._unmount 
    
    I/flutter (30244): #6      _InactiveElements._unmount.<anonymous closure> 
    
    I/flutter (30244): #7      ComponentElement.visitChildren 
    
    I/flutter (30244): #8      _InactiveElements._unmount 
    ...
    
    opened by NeKoFu 12
  • initial example

    initial example

    That's a raw example.

    I haven't checked absolutely everything nor did I do a complete rewrite. I just made the changes so that things work without get-it dependency.

    ProxyProvider has yet to merge, and I'd expect a good chunk of code to disappear once all the variations are available (they have a TODO(rrousselGit)).

    functional_widget is totally optional. I just like it. I'd usually add flutter_hooks too, especially to memoize event handlers. But that's not exactly important here

    opened by rrousselGit 12
  • Dispose issue in feedback tutorial

    Dispose issue in feedback tutorial

    Hi @FilledStacks ,

    I would like to thank you for the awesome job you're doing. I love the architecture you proposed. I'm trying to implement the real stats tutorial using get it and provider.

    The issue is that using registerFactory I get the following: "Stream has already been listened too."

    I followed your suggestion on the Dispose issue in provider architecture part 2, and I implemented the following code:

    StreamSubscription<List<UserFeedback>> subscription;
    
      FeedbackViewModel() {
        subscription = _firestoreService.feedback.listen(_onFeedbackUpdated);
      }
    
      @override
      void dispose() {
        subscription.cancel();
        super.dispose();
      }
    

    I'm still having the same issue.

    Now, if I implement the following code: locator.registerSingleton(FeedbackViewModel()); , remove the dispose method and the subscription variable, I get the following error:

    "A FeedbackViewModel was used after being disposed. Once you have called dispose() on a FeedbackViewModel, it can no longer be used."

    Did you find a way around this bug?

    Regards,

    opened by elhe26 9
  • No type DialogService is registered inside GetIt

    No type DialogService is registered inside GetIt

    This particular service is causing the issue while navigating into LoginScreen.

    Referring to the tutorial https://github.com/FilledStacks/flutter-tutorials/tree/master/039-firebase-custom-start-user-profile

    Inside the Login ModalView file:

    final DialogService _dialogService = locator<DialogService>();

    Above line of code is causing issue. Upon disabling this particular line and its instances, Login screen works, then it throws the next exception when we navigate to Register Screen, again the similar line of code is responsible for the exception.

    The Flutter dependencies used in Pubsec.YAML are:

    dependencies: flutter: sdk: flutter get_it: stacked: firebase_auth: cloud_firestore:

    The Exception is as under:

    flutter: ══╡ EXCEPTION CAUGHT BY WIDGETS LIBRARY ╞═══════════════════════════════════════════════════════════ flutter: The following assertion was thrown building LoginScreen: flutter: No type DialogService is registered inside GetIt. flutter: Did you forget to pass an instance name? flutter: (Did you accidentally do GetIt sl=GetIt.instance(); instead of GetIt sl=GetIt.instance;did you flutter: forget to register it?) flutter: 'package:get_it/get_it_impl.dart': flutter: Failed assertion: line 251 pos 14: 'instanceFactory != null' flutter: flutter: The relevant error-causing widget was: flutter: LoginScreen file:////lib/screens/router.dart:12:21 flutter: flutter: When the exception was thrown, this was the stack: flutter: #2 _GetItImplementation._findFactoryByNameOrType (package:get_it/get_it_impl.dart:251:14) flutter: #3 _GetItImplementation.get (package:get_it/get_it_impl.dart:263:27) flutter: #4 _GetItImplementation.call (package:get_it/get_it_impl.dart:288:12) flutter: #5 new LoginScreenModel (package:<some-pack-name>/screens/user/model/login.dart:11:47) flutter: #6 LoginScreen.build.<anonymous closure> (package:<some-pack-name>/screens/user/login.dart:16:31) flutter: #7 _ViewModelBuilderState._createViewModel (package:stacked/src/view_model_builder.dart:92:39) flutter: #8 _ViewModelBuilderState.initState (package:stacked/src/view_model_builder.dart:82:7) flutter: #9 StatefulElement._firstBuild (package:flutter/src/widgets/framework.dart:4640:58) flutter: #10 ComponentElement.mount (package:flutter/src/widgets/framework.dart:4476:5) flutter: ... Normal element mounting (30 frames) flutter: #40 Element.inflateWidget (package:flutter/src/widgets/framework.dart:3446:14) flutter: #41 MultiChildRenderObjectElement.mount (package:flutter/src/widgets/framework.dart:5947:32) flutter: ... Normal element mounting (119 frames) flutter: #160 Element.inflateWidget (package:flutter/src/widgets/framework.dart:3446:14) flutter: #161 Element.updateChild (package:flutter/src/widgets/framework.dart:3214:18) flutter: #162 RenderObjectElement.updateChildren (package:flutter/src/widgets/framework.dart:5580:32) flutter: #163 MultiChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:5957:17) flutter: #164 Element.updateChild (package:flutter/src/widgets/framework.dart:3201:15) flutter: #165 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4527:16) flutter: #166 StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4675:11) flutter: #167 Element.rebuild (package:flutter/src/widgets/framework.dart:4218:5) flutter: #168 StatefulElement.update (package:flutter/src/widgets/framework.dart:4707:5) flutter: #169 Element.updateChild (package:flutter/src/widgets/framework.dart:3201:15) flutter: #170 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4527:16) flutter: #171 Element.rebuild (package:flutter/src/widgets/framework.dart:4218:5) flutter: #172 ProxyElement.update (package:flutter/src/widgets/framework.dart:4862:5) flutter: #173 _InheritedNotifierElement.update (package:flutter/src/widgets/inherited_notifier.dart:181:11) flutter: #174 Element.updateChild (package:flutter/src/widgets/framework.dart:3201:15) flutter: #175 SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:5837:14) flutter: #176 Element.updateChild (package:flutter/src/widgets/framework.dart:3201:15) flutter: #177 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4527:16) flutter: #178 StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4675:11) flutter: #179 Element.rebuild (package:flutter/src/widgets/framework.dart:4218:5) flutter: #180 StatefulElement.update (package:flutter/src/widgets/framework.dart:4707:5) flutter: #181 Element.updateChild (package:flutter/src/widgets/framework.dart:3201:15) flutter: #182 SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:5837:14) flutter: #183 Element.updateChild (package:flutter/src/widgets/framework.dart:3201:15) flutter: #184 SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:5837:14) flutter: #185 Element.updateChild (package:flutter/src/widgets/framework.dart:3201:15) flutter: #186 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4527:16) flutter: #187 Element.rebuild (package:flutter/src/widgets/framework.dart:4218:5) flutter: #188 StatelessElement.update (package:flutter/src/widgets/framework.dart:4583:5) flutter: #189 Element.updateChild (package:flutter/src/widgets/framework.dart:3201:15) flutter: #190 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4527:16) flutter: #191 StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:4675:11) flutter: #192 Element.rebuild (package:flutter/src/widgets/framework.dart:4218:5) flutter: #193 BuildOwner.buildScope (package:flutter/src/widgets/framework.dart:2627:33) flutter: #194 WidgetsBinding.drawFrame (package:flutter/src/widgets/binding.dart:883:20) flutter: #195 RendererBinding._handlePersistentFrameCallback (package:flutter/src/rendering/binding.dart:284:5) flutter: #196 SchedulerBinding._invokeFrameCallback (package:flutter/src/scheduler/binding.dart:1113:15) flutter: #197 SchedulerBinding.handleDrawFrame (package:flutter/src/scheduler/binding.dart:1052:9) flutter: #198 SchedulerBinding._handleDrawFrame (package:flutter/src/scheduler/binding.dart:968:5) flutter: #202 _invoke (dart:ui/hooks.dart:261:10) flutter: #203 _drawFrame (dart:ui/hooks.dart:219:3) flutter: (elided 5 frames from class _AssertionError and dart:async) flutter: flutter: ════════════════════════════════════════════════════════════════════════════════════════════════════

    opened by akyjoe 8
  • 045-paginated-realtime-firestore Stream if is empty

    045-paginated-realtime-firestore Stream if is empty

    opened by cnkygmr 8
  • 010-provider-architecture Not load post

    010-provider-architecture Not load post

    Hi, I has a problem when run Final example not load post because is produced by Provider.of<User>(context).id in file home_view.dart has 0 on first run.

    opened by sercheo87 7
  • why you use StreamProvider in providerV3 sample code

    why you use StreamProvider in providerV3 sample code

    could you describe me why you use StreamProvider for User ?

    List<SingleChildCloneableWidget> uiConsumableProviders = [
      StreamProvider<User>(
        builder: (context) => Provider.of<AuthenticationService>(context, listen: false).user,
      )
    ];
    
    opened by pishguy 7
  • Force onModelReady

    Force onModelReady

    I am using your BaseModel-BaseWidget arquitecture from 014-provider-v3-updates. I have the following:

    class MyPage extends StatelessWidget {
      @override
      Widget build(BuildContext context) {
        AppModule module = Provider.of<MyModel>(context).appModule;
        return BaseWidget<MyPageViewModel>(
            onModelReady: (model) => model.fetchData(module),
            model: MyPageViewModel(api: Provider.of(context)),
            builder: (context, model, child) => model.busy
                ? Center(
                    child: CircularProgressIndicator(),
                  )
                : Scaffold(
    

    When the module changes I wanted my data to be fetched again, but I see the BaseWidget is only being rebuilt, without calling the onModelReady. I guess this is because the viewModel has not been disposed, right?

    How can I approach these scenario?

    opened by eskalera 7
  • 037 - Advanced URL navigation Navigator issue

    037 - Advanced URL navigation Navigator issue

    Hi, there is no template to report issues so I will jump right to it. With the latest changes and with adding navigatorKey to the MaterialApp, now we cannot easily close scaffold drawer.

    Most users want to close the drawer onTap and be redirected. In the latest code if one tries to close the drawer like this:

        return GestureDetector(
          onTap: () {
            // DON'T EVER USE A SERVICE DIRECTLY IN THE UI TO CHANGE ANY KIND OF STATE
            // SERVICES SHOULD ONLY BE USED FROM A VIEWMODEL
    
            // NEW LINE ADDED TO CLOSE DRAWER
            Navigator.of(context).pop();
            locator<NavigationService>().navigateTo(navigationPath);
          },
    

    it will end up with the following error:

    Navigator operation requested with a context that does not include a Navigator.

    Can you please direct me to a solution of this issue. There is no exposed DrawerController and I can only open the drawer programatically and I am not aware of other solution to close the drawer besides the above-mentioned one (link below): https://api.flutter.dev/flutter/material/Drawer-class.html

    opened by ibosev 6
  • Bump protobufjs from 6.8.8 to 6.11.3 in /041-firestore-security-rules-with-testing/compound/firebase/functions

    Bump protobufjs from 6.8.8 to 6.11.3 in /041-firestore-security-rules-with-testing/compound/firebase/functions

    Bumps protobufjs from 6.8.8 to 6.11.3.

    Release notes

    Sourced from protobufjs's releases.

    v6.11.3

    6.11.3 (2022-05-20)

    Bug Fixes

    v6.11.2

    6.11.2 (2021-04-30)

    • regenerated index.d.ts to fix the unintended breaking change in types.

    v6.11.1

    6.11.1 (2021-04-29)

    Bug Fixes

    v6.11.0

    6.11.0 (2021-04-28)

    Features

    Bug Fixes

    Dependencies

    protobuf.js v6.10.2

    Bug Fixes

    protobuf.js v6.10.1

    ... (truncated)

    Changelog

    Sourced from protobufjs's changelog.

    6.11.3 (2022-05-20)

    Bug Fixes

    6.11.2 (2021-04-30)

    • regenerated index.d.ts to fix the unintended breaking change in types.

    6.11.1 (2021-04-29)

    Bug Fixes

    6.11.0 (2021-04-28)

    Features

    Bug Fixes

    Dependencies

    6.10.2 (2020-11-13)

    Bug Fixes

    6.10.1 (2020-07-16)

    Bug Fixes

    ... (truncated)

    Commits
    Maintainer changes

    This version was pushed to npm by google-wombot, a new releaser for protobufjs since your current version.


    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
    • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
    • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
    • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

    You can disable automated security fix PRs for this repo from the Security Alerts page.

    dependencies 
    opened by dependabot[bot] 0
  • Bump protobufjs from 6.8.8 to 6.11.3 in /035-statemanagement-api-integration/the-basics-functions/functions

    Bump protobufjs from 6.8.8 to 6.11.3 in /035-statemanagement-api-integration/the-basics-functions/functions

    Bumps protobufjs from 6.8.8 to 6.11.3.

    Release notes

    Sourced from protobufjs's releases.

    v6.11.3

    6.11.3 (2022-05-20)

    Bug Fixes

    v6.11.2

    6.11.2 (2021-04-30)

    • regenerated index.d.ts to fix the unintended breaking change in types.

    v6.11.1

    6.11.1 (2021-04-29)

    Bug Fixes

    v6.11.0

    6.11.0 (2021-04-28)

    Features

    Bug Fixes

    Dependencies

    protobuf.js v6.10.2

    Bug Fixes

    protobuf.js v6.10.1

    ... (truncated)

    Changelog

    Sourced from protobufjs's changelog.

    6.11.3 (2022-05-20)

    Bug Fixes

    6.11.2 (2021-04-30)

    • regenerated index.d.ts to fix the unintended breaking change in types.

    6.11.1 (2021-04-29)

    Bug Fixes

    6.11.0 (2021-04-28)

    Features

    Bug Fixes

    Dependencies

    6.10.2 (2020-11-13)

    Bug Fixes

    6.10.1 (2020-07-16)

    Bug Fixes

    ... (truncated)

    Commits
    Maintainer changes

    This version was pushed to npm by google-wombot, a new releaser for protobufjs since your current version.


    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
    • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
    • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
    • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

    You can disable automated security fix PRs for this repo from the Security Alerts page.

    dependencies 
    opened by dependabot[bot] 0
  • Add persistent bottom nav bar code

    Add persistent bottom nav bar code

    This PR add's code for persistent bottom nav bar in stacked

    https://user-images.githubusercontent.com/46024202/163177382-3385e609-a0cc-4395-b0f7-c6d77bca98e5.mov

    opened by isaacadariku 0
  • Shared model

    Shared model

    Hi, I have a question, I have this code:

    StartUpScreen:

    class StartUpScreen extends StatelessWidget {
      const StartUpScreen({Key? key}) : super(key: key);
    
      @override
      Widget build(BuildContext context) {
        var userProvider = context.read<UserProvider>();
        return ViewModelBuilder<StartUpViewModel>.reactive(
          viewModelBuilder: () => StartUpViewModel(),
          onModelReady: (model) => model.handleStartUpLogic(),
          builder: (context, model, child) => Scaffold(
              backgroundColor: Colors.white,
              body: model.isBusy
                  ? const CircularProgressIndicator()
                  : model.isLogged
                      ? const HomeScreen()
                      : LoginScreen()),
        );
      }
    }
    

    and relative view model:

    class StartUpViewModel extends BaseViewModel {
      final AuthenticationService _authenticationService = locator<AuthenticationService>();
    
      bool _isLogged = false;
      bool get isLogged {
        return _isLogged;
      }
    
      Future handleStartUpLogic() async {
        setBusy(true);
        bool hasLoggedInUser = _authenticationService.isUserLoggedIn();
        if (hasLoggedInUser) {
          _isLogged = true;
          setBusy(false);
        } else {
          _isLogged = false;
          setBusy(false);
        }
      }
    }
    

    on lunch application I'm not logged and the app show me LoginScreen:

    class LoginScreen extends StatelessWidget {
      LoginScreen({Key? key}) : super(key: key);
    
      final emailController = TextEditingController();
      final passwordController = TextEditingController();
    
      @override
      Widget build(BuildContext context) {
        return ViewModelBuilder<LoginViewModel>.reactive(
          viewModelBuilder: () => LoginViewModel(),
          builder: (context, model, child) => Scaffold(
            backgroundColor: Colors.white,
            body: Padding(
              padding: const EdgeInsets.symmetric(horizontal: 50),
              child: Column(
                mainAxisSize: MainAxisSize.max,
                mainAxisAlignment: MainAxisAlignment.center,
                crossAxisAlignment: CrossAxisAlignment.center,
                children: <Widget>[
                  SizedBox(
                    height: 150,
                    child: Image.asset('assets/images/title.png'),
                  ),
                  InputField(
                    placeholder: 'Email',
                    controller: emailController,
                  ),
                  verticalSpaceSmall,
                  InputField(
                    placeholder: 'Password',
                    password: true,
                    controller: passwordController,
                  ),
                  verticalSpaceMedium,
                  Row(
                    mainAxisSize: MainAxisSize.max,
                    mainAxisAlignment: MainAxisAlignment.end,
                    children: [
                      BusyButton(
                        title: 'Login',
                        busy: model.isBusy,
                        onPressed: () {
                          model.login(
                            email: emailController.text,
                            password: passwordController.text,
                          );
                        },
                      )
                    ],
                  ),
                  verticalSpaceMedium,
                ],
              ),
            ),
          ),
        );
      }
    }
    

    and relative view model:

    class LoginViewModel extends BaseViewModel {
      final AuthenticationService _authenticationService = locator<AuthenticationService>();
      final DialogService _dialogService = locator<DialogService>();
    
      Future<void> login({
        required String email,
        required String password,
      }) async {
        try {
          setBusy(true);
          await _authenticationService.loginWithEmail(
            email: "myemail",
            password: "mypass!",
          );
          setBusy(false);
        } catch (e) {
          setBusy(false);
          await _dialogService.showDialog(
            title: 'Login Failure',
            description: 'General login failure. Please try again later',
          );
        }
      }
    }
    
    

    The question is, how to change model.isLogged on StartUpViewModel for reload the widget and show the LoginScreen simil to classic provider? I could use navigation but this operation can be useful for other pages as well. for example, in classic provider i've a Page A with total coins, in Page B i add 10 coin, with provider i can update the value with notifyListeners(); without call the server. How to emulate this? it's possible?

    opened by stoppimyse 0
  • Bump ajv from 6.11.0 to 6.12.6 in /041-firestore-security-rules-with-testing/compound/firebase

    Bump ajv from 6.11.0 to 6.12.6 in /041-firestore-security-rules-with-testing/compound/firebase

    Bumps ajv from 6.11.0 to 6.12.6.

    Release notes

    Sourced from ajv's releases.

    v6.12.6

    Fix performance issue of "url" format.

    v6.12.5

    Fix uri scheme validation (@​ChALkeR). Fix boolean schemas with strictKeywords option (#1270)

    v6.12.4

    Fix: coercion of one-item arrays to scalar that should fail validation (failing example).

    v6.12.3

    Pass schema object to processCode function Option for strictNumbers (@​issacgerges, #1128) Fixed vulnerability related to untrusted schemas (CVE-2020-15366)

    v6.12.2

    Removed post-install script

    v6.12.1

    Docs and dependency updates

    v6.12.0

    Improved hostname validation (@​sambauers, #1143) Option keywords to add custom keywords (@​franciscomorais, #1137) Types fixes (@​boenrobot, @​MattiAstedrone) Docs:

    Commits
    • fe59143 6.12.6
    • d580d3e Merge pull request #1298 from ajv-validator/fix-url
    • fd36389 fix: regular expression for "url" format
    • 490e34c docs: link to v7-beta branch
    • 9cd93a1 docs: note about v7 in readme
    • 877d286 Merge pull request #1262 from b4h0-c4t/refactor-opt-object-type
    • f1c8e45 6.12.5
    • 764035e Merge branch 'ChALkeR-chalker/fix-comma'
    • 3798160 Merge branch 'chalker/fix-comma' of git://github.com/ChALkeR/ajv into ChALkeR...
    • a3c7eba Merge branch 'refactor-opt-object-type' of github.com:b4h0-c4t/ajv into refac...
    • Additional commits viewable in compare view

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
    • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
    • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
    • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

    You can disable automated security fix PRs for this repo from the Security Alerts page.

    dependencies 
    opened by dependabot[bot] 0
  • Bump ajv from 6.10.2 to 6.12.6 in /035-statemanagement-api-integration/the-basics-functions/functions

    Bump ajv from 6.10.2 to 6.12.6 in /035-statemanagement-api-integration/the-basics-functions/functions

    Bumps ajv from 6.10.2 to 6.12.6.

    Release notes

    Sourced from ajv's releases.

    v6.12.6

    Fix performance issue of "url" format.

    v6.12.5

    Fix uri scheme validation (@​ChALkeR). Fix boolean schemas with strictKeywords option (#1270)

    v6.12.4

    Fix: coercion of one-item arrays to scalar that should fail validation (failing example).

    v6.12.3

    Pass schema object to processCode function Option for strictNumbers (@​issacgerges, #1128) Fixed vulnerability related to untrusted schemas (CVE-2020-15366)

    v6.12.2

    Removed post-install script

    v6.12.1

    Docs and dependency updates

    v6.12.0

    Improved hostname validation (@​sambauers, #1143) Option keywords to add custom keywords (@​franciscomorais, #1137) Types fixes (@​boenrobot, @​MattiAstedrone) Docs:

    v6.11.0

    Time formats support two digit and colon-less variants of timezone offset (#1061 , @​cjpillsbury) Docs: RegExp related security considerations Tests: Disabled failing typescript test

    Commits
    • fe59143 6.12.6
    • d580d3e Merge pull request #1298 from ajv-validator/fix-url
    • fd36389 fix: regular expression for "url" format
    • 490e34c docs: link to v7-beta branch
    • 9cd93a1 docs: note about v7 in readme
    • 877d286 Merge pull request #1262 from b4h0-c4t/refactor-opt-object-type
    • f1c8e45 6.12.5
    • 764035e Merge branch 'ChALkeR-chalker/fix-comma'
    • 3798160 Merge branch 'chalker/fix-comma' of git://github.com/ChALkeR/ajv into ChALkeR...
    • a3c7eba Merge branch 'refactor-opt-object-type' of github.com:b4h0-c4t/ajv into refac...
    • Additional commits viewable in compare view

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
    • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
    • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
    • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

    You can disable automated security fix PRs for this repo from the Security Alerts page.

    dependencies 
    opened by dependabot[bot] 0
Owner
Dane Mackier
Full-Stack applications developer focussed on complete Mobile products.
Dane Mackier
Flutter tutorial - This is my first Flutter tutorial app. Thanks to The Net Ninja youtube channel for this wonderful tutorial

ninja_id A new Flutter project. Getting Started This project is a starting point for a Flutter application. A few resources to get you started if this

null 1 Jun 9, 2022
All of my open source flutter and dart projects, tutorials are published here.

Flutter In this repository I publish all of my open source flutter, dart projects, and tutorials. Written Tutorials Dart Programming Language for Prog

Mahmud Ahsan 137 Nov 20, 2022
Write iOS&Android Code using Dart. This package liberates you from redundant glue code and low performance of Flutter Channel.

Dart_Native Dart_Native operates as both a code generator tool and a bridge to communicate between Dart and native APIs. Replaces the low-performing F

DartNative 886 Nov 16, 2022
A set of widgets to help with the implementation of the Provider architecture as shown by FilledStacks

Provider Architecture - Deprecated on 21 April 2020 Notice V2 of this package is renamed to Stacked Stacked is the name of the architecture that was o

Dane Mackier 84 Dec 16, 2021
Repository containing source code for the tutorials made using with flutter

Flutter Tutorials Repository Containing Source code for tutorials found here: https://petercoding.com Note: Don't forgot to run pub get or just open p

Peter Haddad 18 Sep 20, 2022
Repository containing source code for the tutorials made using firebase with flutter

Firebase-Flutter Tutorials Repository Containing Source code for tutorials found here: https://petercoding.com Note: Don't forgot to run pub get or ju

Peter Haddad 228 Nov 17, 2022
Find The Latest trending and upcoming movies and tv shows with MovieDB app. The app contains all info about movies and tv shows. find similar movies or shows, Browse all genres, video trailers, backdrops, logos, and posters.

MovieDB App Features. Dynamic Theming Search Functionality Onboarding-Screen Select favourite movie Home Screen Tranding movie Movies different catego

Ansh rathod 77 Nov 24, 2022
Deepak Sharma 146 Nov 13, 2022
This repo contains a collection of permission related Flutter plugins which can be used to request permissions to access device resources in a cross-platform way.

Flutter Permission Plugins Deprecation Notice This repository has been replaced by the Flutter permission_handler plugin and will not longer be mainta

Baseflow 51 Dec 13, 2021
An Awesome list of all the Flutter video Tutorials from Whatsupcoders

Whatsupcoders-flutter An Awesome list of all the Flutter video Tutorials from Whatsupcoders Channel Whatsupcoders offers you tons of free tutorials re

Whatsupcoders 41 May 27, 2022
Sample code for Flutter tutorials

Welcome to Flutter ShareWhatYouKnow ?? In this Github repository I share the source code for the tutorial articles that I published. You can find the

Cagatay Ulusoy 251 Nov 21, 2022
Search and view popular Youtube videos with Youtube API in Flutter App

getx_bottom_nav_sample The sample of AnimatedBottomNavBar with GetX 주요 Package 설명 1.url_launcher url_launcher pub.dev flutter 에서 인앱, 외부 브라우저로 연길 시켜 주는

Jacob Ko 1 Dec 25, 2021
Youtube Clone App with GetX & Youtube Data Api V3 [MVC pattern]

Youtube App ✍?? Youtube App Clone with GetX & Youtube Data Api V3 [MVC pattern] ????‍?? Youtube App app is open-source Youtube App app for Android & i

null 6 Nov 6, 2022
Flutter youtube downloader - A Windows App made in Flutter to download mp3 or mp4 from a Youtube video

youtube_downloader A Windows App made in Flutter to download mp3 or mp4 from a Y

Sakshham Bhagat 3 Aug 25, 2022
dna, dart native access. A lightweight dart to native super channel plugin

dna, dart native access. A lightweight dart to native super channel plugin, You can use it to invoke any native code directly in contextual and chained dart code.

Assuner 14 Jul 11, 2022
Master Channel cannot use Glass Floating Action Button

Problem Master Channel cannot use GlassFloatingActionButton. About This package

null 7 Oct 2, 2022
SMS Receiver Channel For Android

SMS Receiver Channel SMS Receiver Channel For Android Getting Started Use channel on the client_side (flutter) and the platform_side (android) and inv

Niloofar Amerian 2 Nov 3, 2022
A flutter plugin about qr code or bar code scan , it can scan from file、url、memory and camera qr code or bar code .Welcome to feedback your issue.

r_scan A flutter plugin about qr code or bar code scan , it can scan from file、url、memory and camera qr code or bar code .Welcome to feedback your iss

PengHui Li 112 Nov 11, 2022