Need help with flutter_architecture_samples?
Click the “chat” button below for chat support from the developer who created it, or find similar developers for support.

About the developer

brianegan
7.4K Stars 1.5K Forks BSD 3-Clause "New" or "Revised" License 336 Commits 42 Opened issues

Description

TodoMVC for Flutter

Services available

!
?

Need anything else?

Contributors list

# 6,174
Dart
Ruby
Flutter
Redux
138 commits
# 17,245
Dart
Flutter
Ruby
Redux
41 commits
# 10,183
Dart
Flutter
Objecti...
hashcod...
11 commits
# 40,928
Dart
Flutter
Kotlin
flutter...
11 commits
# 46,998
Dart
Flutter
mobx
pub
9 commits
# 54,187
quasar-...
Flutter
Dart
Redux
7 commits
# 52,381
Flutter
Dart
Redux
Kotlin
7 commits
# 53,817
Dart
Redux
immutab...
Flutter
7 commits
# 1,384
Dart
Flutter
flutter...
Kotlin
6 commits
# 25,917
Dart
Flutter
mobx
pub
6 commits
# 30,115
Dart
Flutter
sharedp...
Redux
6 commits
# 13,746
Flutter
Dart
filedow...
github-...
5 commits
# 62,329
Dart
Flutter
dart2
rxdart
5 commits
# 71,051
Kotlin
mvvm-an...
mvvm-da...
Dart
4 commits
# 66,080
Flutter
Dart
Redux
acm
4 commits
# 32,262
Dart
blur-ba...
swift-f...
swift-3
2 commits
# 103,155
Flutter
Dart
Redux
Kotlin
2 commits
# 102,126
Django
eventso...
python3
Bootstr...
2 commits
# 46,175
Dart
Flutter
Redux
elixir-...
2 commits
# 18,936
Dart
Flutter
Redux
GraphQL
1 commit

flutterarchitecturesamples

Build Status Build Status codecov

List of Todos Screen

TodoMVC for Flutter!

Flutter provides a lot of flexibility in deciding how to organize and architect your apps. While this freedom is very valuable, it can also lead to apps with large classes, inconsistent naming schemes, as well as mismatching or missing architectures. These types of issues can make testing, maintaining and extending your apps difficult.

The Flutter Architecture Samples project demonstrates strategies to help solve or avoid these common problems. This project implements the same app using different architectural concepts and tools.

You can use the samples in this project as a learning reference, or as a starting point for creating your own apps. The focus of this project is on demonstrating how to structure your code, design your architecture, and the eventual impact of adopting these patterns on testing and maintaining your app. You can use the techniques demonstrated here in many different ways to build apps. Your own particular priorities will impact how you implement the concepts in these projects, so you should not consider these samples to be canonical examples. To ensure the focus is kept on the aims described above, the app uses a simple UI.

Current Samples

Supporting Code

  • integration_tests - Demonstrates how to write selenium-style integration (aka end to end) tests using the Page Object Model. This test suite is run against all samples.
  • todosrepositorycore - Defines the core abstract classes for loading and saving data so that storage can be implemented in various ways, such as file storage or firebase for mobile projects, or window.localStorage for web projects.
  • todosrepositorylocal_storage - Implements the todos repository using the file system, window.localStorage, and SharedPreferences as the data source.
  • firebaseflutterrepository - Implements the todos repository using firestore as the data source.
  • firebasertdbflutter_repository - Implements the todos repository using firebase real-time database as the data source.

Running the samples

iOS / Android

cd 
flutter run 

Web

Make sure you're on Flutter version "Flutter 1.12.13+hotfix.6 • channel beta" or newer. Not all samples support web at this time, so please check the sample directory for a

lib/main_web.dart
file.
cd 
flutter run -d chrome -t lib/main_web.dart

Why a todo app?

The app in this project aims to be simple enough that you can understand it quickly, but complex enough to showcase difficult design decisions and testing scenarios. For more information, see the app's specification.

Be excellent to each other

This Repo is meant as a discussion platform for various architectures. Let us debate these ideas vigorously, but let us be excellent to each other in the process!

While healthy debate and contributions are very welcome, trolls are not. Read the code of conduct for detailed information.

Contributing

Feel free to join in the discussion, file issues, and we'd love to have more samples added! Please read the CONTRIBUTING file for guidance :)

License

All code in this repo is MIT licensed.

Attribution

All of these ideas and even some of the language are directly influenced by two projects:

Contributors

I'd like to thank all of the folks who have helped write new samples, improve the current implementations, and added documentation! You're amazing! :)

We use cookies. If you continue to browse the site, you agree to the use of cookies. For more information on our use of cookies please see our Privacy Policy.