Member-only story
Loving Flutter App Architecture By Throwing Out Most Of It.
Why do we need app architecture or want it? It should be because it allows organizing things, so we can get to UX design. There is a group of people insisting that we need enterprise heavy-laden arch when clearly we should be striving towards a very thin app architecture approach. Let me explain.
The Poisons Called Clean Architecture and Domain Driven Design
Both Clean Architecture And Domain Driven Design are about specifying OOP inheritance in certain OOP patterns such as interface-adapter to control communication between the view and model layers. But you have to write extra boilerplate to achieve it. But why do this?
Flutter views, i.e. screens, are declarative and not OOP imperative exception the implemented part. And, two the local and remote API access can actually be done as services facades, no real need of the repository pattern in the first place.
Let me show you the counter app example of a thin app architecture approach.
A Counter App Thin Architecture Approach
First, my thanks to the folks at GSkinner for first developing this approach; detailed in this article titled, WidgetView: