![blocs app modals blocs app modals](https://koenig-media.raywenderlich.com/uploads/2020/08/04-BLoC-diagram-1.png)
(If you're familiar with React Redux: Yep Bloc sounds a lot like React Redux, because they are both State Management Frameworks) 2 Flutter Widgets for PineTime There's a good way to handle this messy state in Flutter apps. What happens when the app loses track of its state? Or talking to Bluetooth gadgets like PineTime. Nope! Behind the scenes, the app could be calling some REST API on the web. It just reacts to our tapping and updates the display.
![blocs app modals blocs app modals](https://koenig-media.raywenderlich.com/uploads/2020/08/01-empty-app-1.png)
What could go wrong?Ī mobile app is a simple thing.
#BLOCS APP MODALS FOR ANDROID#
It's easy to build a mobile app for Android and iOS with Flutter. Read on to learn how we do this with the Bloc Library for State Management.
![blocs app modals blocs app modals](https://blocs.store/wp-content/uploads/2021/10/bae4fc53c5a2-1.png)
Today we'll recode the app so that it's more human-friendly, like this. In the previous article "Convert Go to Flutter and Dart for PineTime Companion App" we have built a technically functional (but barely human) app that sends Bluetooth Low Energy commands to PineTime. That's why we have selected Flutter for creating the open source Android and iOS Companion App for PineTime Smart Watch: For updating firmware, syncing date/time, pushing mobile notifications, controlling our smart home gadgets. The programming language is modern (Dart), the debugging tools are excellent (VSCode and Dart DevTools). PineTime Companion App running on an Android phone, fetching the firmware versions from PineTime Smart Watch wirelesslyįlutter is awesome for creating mobile apps for Android and iOS. 7 Business Logic, States and Events in Bloc.5 Handle Bluetooth LE Response from PineTime.4 Send Bluetooth LE Request to PineTime.Flutter State Management with Bloc for PineTime Companion App