
Singletons in Flutter: How to Avoid Them and What to do Instead
12 min read
An introduction to singletons in Flutter: what problems they solve, what other ones they introduce, and what are their alternatives.
An introduction to singletons in Flutter: what problems they solve, what other ones they introduce, and what are their alternatives.
Service classes are the ideal place to store logic that depends on multiple data sources or repositories. Let's explore them by building a shopping cart feature.
How to implement controller classes that can hold business logic, manage widget state, and interact with repositories in the data layer.
An overview of the feature-first and layer-first approaches when choosing a project structure for medium/large Flutter apps, along with their tradeoffs and common pitfalls.
An introduction to a new App Architecture based on Riverpod, and comparison with other popular ones such as MVC, MVVM, Bloc, Stacked & Clean Architecture.
A curated list of popular VSCode shortcuts, extensions & settings to speed-up your Flutter development workflow and code like a pro.
An in-depth overview of the repository pattern in Flutter: what it is, when to use it, and various implementation strategies along with their tradeoffs.
And in-depth performance comparison of my new home page, built with Flutter web vs standard web technologies. All benchmarks were run with Google PageSpeed Insights and WebPageTest.org.
A complete guide to the Riverpod package for Flutter state management. Included: core concepts & how to use all the available providers. Updated to Riverpod 1.0.
Learn how to parse JSON and define type-safe model classes that can handle validation, nullable/optional values, and complex/nested JSON data.
A complete tour of Null Safety & non-nullable types, the syntax changes they introduce in Dart 2.12, and how to use them in practice.
A curated list of useful Dart tips that will improve your coding style as a Flutter developer.