The Complete Flutter Course: Build Android, iOS and Web Apps
Riverpod course: Riverpod in a real app
Many Riverpod examples stop at a counter. This guide picks out the lessons of The Complete Flutter Course: Build Android, iOS and Web Apps where Riverpod is learnt on a counter and then runs a complete app: sign-in, forms, live data from Cloud Firestore and a view model, followed by a lesson that fixes the app's rebuilding with a StreamProvider. It is also plain about the parts of Riverpod the lessons do not use.
Taught by Sagnik Bhattacharya and Paulina Knop
What you will be able to do
You will be able to:
- Wrap an app in ProviderScope and read providers from ConsumerWidgets with ref.watch.
- Expose a view model through a ChangeNotifierProvider and rebuild the views that watch it.
- Reset state that no screen is using with autoDispose.
- Move a sign-in check into a StreamProvider so widgets get the current value without endless rebuilds.
- Keep the budget app's totals calculation in its view model, and its documents in model classes.
Projects
What you will build.
The course has nine projects. These two matter most here.
-
Project 06
Counter with Provider and Riverpod
Riverpod on its own, small enough to see every part before it carries a real app.
-
Project 08
Budget app
Riverpod running sign-in, Firestore data and an MVVM view model across phone and web layouts.
Lessons
The lessons that matter, in course order.
The Complete Flutter Course: Build Android, iOS and Web Apps has 223 lessons. This page picks out 50 of them, 5 h 46 min of video. Each lesson keeps its number in the course.
Where to start
Lesson 156 Riverpod, the successor to Provider
Start at Lesson 156. If ChangeNotifier is new to you, watch the Provider counter at Lesson 155 first, since the Riverpod lessons build on it; the budget app then begins at Lesson 169.
50 of 223 lessons · 5 h 46 min
20 Advanced State management Riverpod as Provider's successor: ProviderScope and an autoDispose ChangeNotifierProvider, then a counter with ConsumerWidget, WidgetRef and ref.watch.
- 156 Start here Riverpod, the successor to Provider ProviderScope and an autoDispose ChangeNotifierProvider 4 min
- 157 A counter with Riverpod and ConsumerWidget WidgetRef, ref.watch and when autoDispose resets state 5 min
22 Budget App using Flutter Riverpod and MVVM architecture The budget app on Riverpod and MVVM: sign-in state, a view model wired to the login buttons, pop-up forms that save to Firestore and totals that follow the streams.
- 169 Set up Firebase, Riverpod and the login screen Three platforms, sign-in state, and email and password fields 1 h
- 170 Creating a custom reusable widget An Open Sans text widget and the styled register button 4 min
- 171 Rows and user registration Why a Row re-centres the Column, then registering by email 4 min
- 172 Error pop-ups An AlertDialog that shows Firebase's error messages 7 min
- 173 Cleaning error messages with RegExp Strip the bracketed code from Firebase errors with replaceAll 4 min
- 174 Creating the log-in button An OR label, then signInWithEmailAndPassword and its errors 6 min
- 175 Registering and logging in to the app Test both buttons on Chrome after an emulator network bug 4 min
- 176 Creating the Google Sign-In button The sign_button package and kIsWeb to pick web or mobile 3 min
- 177 Google Sign-In functions for web and mobile A pop-up on the web and the google_sign_in package on phones 5 min
- 178 Connecting Google Sign-In to Firebase Auth Turn Google tokens into a credential for signInWithCredential 2 min
- 179 Google button wiring and the web login page Pick the web or mobile sign-in, then start the web layout 4 min
- 180 Adding image assets The login illustration and logo on the web login page 2 min
- 181 Email field for the web login A TextFormField with rounded borders and an email icon 5 min
- 182 Password field for the web login A show-or-hide toggle, then the start of the register button 3 min
- 183 Register and log-in buttons for the web Styled buttons with an OR label, wired to the view model 4 min
- 184 The Google Sign-In button on the web A large Google button, kIsWeb and a placeholder dashboard 3 min
- 185 Testing sign-in on the web and a phone Email and Google sign-in on Chrome, Google on a phone 4 min
- 186 A Firestore rule and the totals calculation A signed-in-only rule, then lists and the expense total loop 6 min
- 187 Budget left and the dashboard drawer Income total and a drawer header with a round logo 4 min
- 188 Log-out button in the drawer AppBar icon theme, then signOut from a styled button 6 min
- 189 Social media links An Instagram icon button with url_launcher and an SVG 2 min
- 190 Twitter link and the dashboard title A reusable Poppins text widget for the AppBar title 5 min
- 191 Reset button and TODO comments An AppBar action left empty and marked with a TODO comment 3 min
- 192 Building the totals box A ListView body and a black rounded container for totals 4 min
- 193 Totals labels and a vertical divider Poppins labels and a Divider turned with RotatedBox 4 min
- 194 Totals values and the add expense button Budget left and both totals, then a styled black button 6 min
- 195 The add expense pop-up A dialog with a Form, a GlobalKey and two text controllers 6 min
- 196 A reusable text form widget Label, validator, digits-only input and red error borders 7 min
- 197 Name and amount fields for expenses The text form widget in the pop-up, validated on Save 7 min
- 198 A reference to the users collection A CollectionReference so later code stays short 1 min
- 199 Saving expenses to Cloud Firestore A per-user expenses collection, error dialog and test entry 7 min
- 200 Creating the add income button Check the expense in the Firebase console, then the button 4 min
- 201 The add income pop-up A dialog with a form key and controllers for name and amount 4 min
- 202 Name and amount fields for income Validated fields, with digits-only amounts on both forms 3 min
- 203 Saving income to Cloud Firestore Validate, save to the incomes collection and close the pop-up 5 min
- 204 Expenses list box on mobile A heading and a bordered container to hold the expenses 3 min
- 205 Showing expenses with ListView.builder Name and amount rows, then the incomes box beside them 6 min
- 206 Incomes list and the expenses stream Finish the mobile layout, then listen with snapshots() 4 min
- 207 Reading Firestore documents into clean lists Empty the lists on each update to avoid duplicates 4 min
- 208 Starting the streams only once An isLoading flag to stay within Firestore's free reads 4 min
- 209 Resetting the budget, then the web dashboard Delete every expense and income, then copy logic to the web 6 min
- 210 Web dashboard drawer and AppBar Logo, log-out button, social links and the Dashboard title 8 min
- 211 Web dashboard layout and add expense button Reset action, a large illustration and the first button 5 min
- 212 Add expense and add income buttons on the web Icon buttons that open the same pop-ups as on mobile 6 min
- 213 Totals box for the web dashboard Budget left, total expense and total income at a larger size 7 min
- 214 Expenses list on the web dashboard A black card with a heading and a ListView of expenses 10 min
- 215 Incomes list and the finished budget app Test with a second account, reset and try other colours 8 min
23 Budget app: performance optimisation and code reuse The rebuilding fixed by moving the sign-in check to a StreamProvider, then shared widgets, totals moved into the view model and a model class with fromJson.
- 216 Performance optimisation and code reuse StreamProvider for sign-in, shared widgets and a model class 58 min
Instructors
Who teaches it.
Instructor, Flutter
Paulina Knop
Flutter developer and curriculum designer. Teaches the Flutter course.
Questions
Asked before starting.
Where can I see Riverpod running a complete Flutter app, not just a counter?
In The Complete Flutter Course: Build Android, iOS and Web Apps from Coding Liquids, which builds a budget app on Riverpod and MVVM: email and Google sign-in, pop-up forms that save to Cloud Firestore, totals that update live, and layouts for phones and wide screens. A counter comes first to show the parts. This guide picks out 50 lessons (5 hours 46 minutes) of Riverpod at work; anyone who wants Riverpod's Notifier classes should read the answer on them below.
Which kinds of Riverpod provider appear in the lessons?
The lessons use ChangeNotifierProvider, with autoDispose for the counter and to expose the budget app's view model, and StreamProvider, which hands widgets the sign-in state from a stream. Around them The Complete Flutter Course: Build Android, iOS and Web Apps uses ProviderScope, ConsumerWidget, WidgetRef and ref.watch. Notifier and AsyncNotifier, the classes Riverpod's own examples use, are not covered.
Does the course use Riverpod's Notifier classes or code generation?
No. The Complete Flutter Course: Build Android, iOS and Web Apps uses ChangeNotifierProvider, which Riverpod's documentation has since moved to a legacy import: still usable, but no longer what it recommends. Its examples use Notifier and AsyncNotifier, often with code generation, and neither is taught. The ideas carry over directly: a provider holds state outside the widgets, and widgets watch it and rebuild.
How does Riverpod work with MVVM in the budget app?
The view model is a ChangeNotifier that holds the app's state and its actions, such as signing in, and a ChangeNotifierProvider makes it available to every view. The views watch it through Riverpod's ref.watch and rebuild when it notifies them. The Complete Flutter Course: Build Android, iOS and Web Apps sets this up at Lesson 169, and later moves the totals calculation out of the views into the view model.
How does the course stop needless rebuilds with Riverpod?
By moving the sign-in check into a StreamProvider. Before that change the budget app kept rebuilding; afterwards, widgets receive the current sign-in state from the stream and rebuild only when it changes. The Complete Flutter Course: Build Android, iOS and Web Apps makes the fix at Lesson 216, a lesson that also turns repeated code into shared widgets and adds a model class.
Do I need to know Provider before the Riverpod lessons?
Not to start, but it helps. The Complete Flutter Course: Build Android, iOS and Web Apps teaches Provider just before Riverpod, and its Riverpod counter keeps the same ChangeNotifier, so watching the Provider counter at Lesson 155 makes the Riverpod one at Lesson 157 quicker to follow. The budget app itself uses Riverpod alone.
Flutter
See the whole course.
The Complete Flutter Course: Build Android, iOS and Web Apps: 25 hours of video in 223 lessons, built around 9 projects, with lifetime access, a Certificate of Completion and a 14-day money-back guarantee.
The same course
For another background, goal, topic or comparison.
By background
By goal
By topic
- Dart
- State management
- Firebase
- Widgets and layouts
- UI design and styling
- App architecture
- Sign-in and authentication
- Cloud Firestore
- REST APIs with Dio
- Navigation and routing
- Responsive layouts
- Animations and gestures
- Flutter web
- Set-up on Windows and Mac
- Forms and validation
- Futures and Streams
- CI with GitHub Actions
- Reusable widgets
- Debugging
- Packages from pub.dev
Comparisons
- Flutter or React Native
- Which framework to learn
- Course or free tutorials
- Flutter or native Android
- Flutter or Swift
- Flutter or Kotlin Multiplatform
- Flutter or FlutterFlow
- Learn Flutter or use AI
- Riverpod, BLoC or Provider
- Firebase or Supabase
- Flutter web or React
- Dart or JavaScript
- Flutter or Ionic
- Flutter or .NET MAUI
- VS Code or Android Studio