Рет қаралды 15,957
Mixing UI and logic inside Flutter widgets is bad. Here's how to refactor a simple app for better separation of concerns, immutability, and type safety using Freezed & State Notifier.
Written tutorial here: 👇👇
codewithandrea.com/videos/flu...
As a bonus, here's a movie app built to compare Provider, flutter_bloc and Riverpod:
github.com/bizz84/movie_app_s...
CONTENTS:
00:00 - Intro
02:03 - Example Starter Project: Create Profile Page with setState
05:59 - ChangeNotifier implementation and its drawbacks
12:07 - Freezed package
15:47 - StateNotifier
16:55 - Using Freezed + StateNotifier + Provider
20:24 - Wrap Up
21:53 - Movie app on GitHub
Join my FREE email course to become a Flutter expert with the best resources, at your own pace: codewithandrea.com/newsletter/
Want more? Check out all my Flutter courses: 👇👇
codewithandrea.com/courses/
Happy coding!