Complex Dependency Problems, Easy Solutions
Flutter Dependency Injection Guide
Increasingly complex dependency problems 🚨
- The first problem you'll run into as your app grows is that it can easily become spaghetti code .
- If you develop while paying attention to dependencies to avoid spaghetti code, you will end up applying design patterns.
- Even if you develop using clean architecture, the code for injecting dependencies ends up becoming quite complex.
- In this lecture, we will present a guide to proper dependency injection in Flutter projects.
DI Library 📖
Flutter has many libraries that help with DI (dependency injection).
In this tutorial we will use the Injectable library, which does not depend on any specific state management tool.
Injectable library used in lectures
Who should take this course 🙆♀️
If your DI setup so far is similar to or worse than the following code, then you should take this course.


So, after listening to the lecture!
- ✅ After taking this course, the code where people directly do DI, as shown above, will be removed.
- ✅ You can deliver instances in the desired format at the appropriate time.
Why DI is needed
Let me give you some perspective.
This is structured so that you can feel the need for DI by refactoring or rewriting examples covered in previous lectures from a different perspective.
Refactoring part 📚
When developing small apps, you may thinklessly use all objects as singletons. However, this is not a good practice for medium-sized or larger apps. Learn about this problem while refactoring existing apps.
- This is a refactoring course that starts by downloading the source code of 'Flutter Intermediate Part 1 - Clean Architecture'.
- As we work through the issues, we refine the code to make it better.
Rewrite 📚
Have you ever experienced delays in the development period due to implementing detailed functions when creating an app? Experience a new development method by rewriting the 'Mask Inventory' app in a way that considers clean architecture and DI.
Leverage DI to quickly build apps by mocking data and easily replace it with real data later.
- At first, we develop the app by testing it based on fake objects.
- After the app is complete, we use the DI library to replace it with real data.
[Oh Jun-seok's Flutter App Development Series] Lecture Selection Guide 👀
Make sure this is the course you need to study.
(Click on the image to view it in a new window.)
Things to note before taking the class 📢
This course will be conducted in the following environment:
Practice environment
- Operating System and Version (OS): Targeting Android in a macOS environment
- Tools used: Android Studio Flamingo or higher, Flutter 3, Dart 3 or higher
Learning Materials
- We provide a download of starter code for the refactoring section.
- The rewrite section provides the completed source code.
Player knowledge and notes, related lectures
- This is an intermediate course for those who have previously learned MVVM and Clean Architecture.