How To Create Notifiers With The Riverpod Generator In Flutter

Introduction One year ago I avoided code generation as best as I could. I always thought that it is way better to write the code yourself so that you know what happens. With generators, there is usually a different syntax with annotations and eventually some code pops out that doesn’t really look like what you have declared. But my view has changed. Now, I am always in favor of generators. And for all those struggling with it, I created this article. Learn how to create notifiers with the Riverpod generator in Flutter in the most simple way! ...

September 28, 2024 · 8 min · xeladu

How To Use The Flutter Badge Widget

Introduction Let’s say you have a notification icon and want to display the number of new messages. Or you have a shop with limited items that you want to advertise. Or you have a list and want to put the index number to every item. All those use cases can be accomplished with the Badge widget. All those simple solutions can be implemented within minutes. Here is how to use the Flutter Badge widget. ...

September 21, 2024 · 3 min · xeladu

How To Make Rounded Profile Pictures In Flutter

Introduction For your Instagram clone or your member app: Here is how to make rounded profile pictures in Flutter. An easy and fast solution for all app types! In this article, I am going to show you how to make rounded profile pictures in Flutter apps. Why? Because it’s state of the art on many well-known websites. Even Medium uses them, just take a look here: ...

September 20, 2024 · 3 min · xeladu

How To Prevent A Double Click On Buttons In Flutter Apps

Introduction Get rid of annoying bugs and learn how to prevent a double click on buttons in Flutter apps with this easy approach. Your users will also thank you for this! We always assume the best. All people are treated equally, nobody wants war, and users only click once on a button and wait patiently until something happens. Sadly, I can’t fix everything but for the last point, I have a tip for you. Here is how to prevent a double click on buttons in Flutter apps. ...

September 19, 2024 · 3 min · xeladu

How To Monitor Your Mobile Apps With Firebase Crashlytics

Introduction Learn why your apps crash and why you get complaints from users. Here is how to monitor your mobile apps with Firebase Crashlytics. Firebase Crashlytics is a light-weight solution to get insight about why your users get app crashes and exception messages. It is part of the Firebase cloud services, but can be used for free and supports mobile apps. A dashboard shows you in detail your app metrics and allows inspecting reported crashes in detail. You get information about the exception, the exact line of code, and also the current stack trace at that time. ...

August 24, 2024 · 5 min · xeladu

How To Set Up A Free Repository For Your Flutter Packages

Introduction Here is how to set up a free repository for your Flutter packages with Cloudsmith in no time! A package repository has many benefits over packages in local folders or GitHub repositories. If you want to publish your package publicly, you usually are fine with pub.dev. In case you need a private solution, continue reading here. I’ll show you how to set up a free repository for your Flutter packages with Cloudsmith. ...

July 22, 2024 · 7 min · xeladu

How You Can Find Out If Two Flutter Objects Are Equal Or Not

Introduction Built-In vs external package: Here are two essential methods of how you can find out if two Flutter objects are equal or not. Equality comparison is essential in any kind of app. Duplicate objects are often undesired. In this article I’ll demonstrate how you can find out if two Flutter objects are equal or not. You might probably know the drill from other programming languages and Dart makes no exception here. The article will show you two ways of comparison. A longer one with built-in methods provided by Dart and another one that relies on an external package but is less verbose. ...

July 8, 2024 · 3 min · xeladu

How To Add Password Manager Support To Your Flutter Apps

Introduction Let’s welcome Bitwarden, KeePass, LastPass, and others. Here is how to add password manager support to your Flutter apps. In addition, you can use other autofill options for credit cards, birthdays, address data, and more in the same way! Password managers save us time and help choosing stronger and more diverse passwords in general. Instead of remembering hundreds of credentials for all your sites, a master password is enough. In this article I will show you how to add password manager support to your Flutter apps. In addition, you also can configure this to support autofills for emails, username, birthdays, address data, or credit card information! ...

July 1, 2024 · 7 min · xeladu

How To Track Your Location In A Flutter App

Introduction Here is a deep dive into GPS, permissions, and manifests. Learn how to track your location in a Flutter app. Find out how to collect location data while your app is in the background. There are also tips included to prevent the OS from terminating your app after some time. Working with location data in mobile-aware apps is a common use case in the current app ecosystem. In this deep dive I will show you everything you need to know about how to track your location in a Flutter app. No matter if you want a to put a pin on a map with the current location or track a device continuously for hours, everything is possible. ...

June 12, 2024 · 8 min · xeladu

How To Use Riverpod In Flutter Apps - A Practical Approach

Introduction Here is my practical guide about Riverpod. Learn how to use Riverpod in Flutter apps with simple code examples. Explore AsyncNotifierProvider, NotifierProvider, and FutureProvider in real-world scenarios. Riverpod is probably one of the top 2 state management solutions in Flutter apps together with BLoC according to my observations. In this guide, I want to show you some real-world use cases and how you can implement them with Riverpod. I assume you already used Riverpod before and gained some first-hand experience. So, let’s get started on how to use Riverpod in Flutter apps. ...

June 1, 2024 · 17 min · xeladu

How To Manage A Flutter Monorepo With Multiple Packages

Introduction Here is how to manage a Flutter monorepo with multiple packages and melos instead of using shell scripts. Repository administration is really easy with this field-tested tool! I have some private Flutter packages in single repositories on GitHub. And because they are private, I had some authentication issues with transitive dependencies. But then someone guided me into another direction → monorepo. Here is a quick start guide of how to manage a Flutter monorepo with multiple packages and melos. ...

May 10, 2024 · 5 min · xeladu

A Quick Introduction To Different Dart Constructors

Introduction Default, named, constant, factory?!? Here is a quick introduction to different Dart constructors. Knowing the differences can make your code way more readable! Everybody needs to use constructors. And everybody needs to know what’s possible with them. So here is a quick introduction to different Dart constructors. Default Constructor The default constructor is the constructor type you probably use the most. It creates an instance of an object and is essential in any object-oriented programming language. Here is a small code example: ...

April 2, 2024 · 5 min · xeladu

How To Use Firebase Cloud Firestore With A Flutter App

Introduction In this article, I guide you through the setup steps for Cloud Firestore and show you how to use Firebase Cloud Firestore with a Flutter app. We take a look at CRUD operations, security rules, and some pitfalls to avoid. Firebase Cloud Firestore is a scalable NoSQL cloud database where you can store relevant data for your apps. It is very flexible and can be secured with access rules. You will learn ow to use Firebase Cloud Firestore with a Flutter app. In the following sections, we’ll talk about ...

March 21, 2024 · 6 min · xeladu

How To Make HTTP Requests With Flutter And Parse JSON Result Data

Introduction This short article shows how to perform HTTP requests from a Flutter application. We have a look at the most common request types GET, POST, PUT, and DELETE. Performing HTTP requests is a must-have for every app nowadays. In this article, I am going to show you how to add this capability to your Flutter app. We will have a look at two packages to accomplish this task: The http package and the dio package. They are very similar and you can use whatever you like more. In the end, we focus on parsing JSON results from requests, so that the data can be used within our app. ...

March 17, 2024 · 4 min · xeladu

How I Created An Instagram Clone With Flutter And Firebase

Introduction Learn how I created an Instagram clone with Flutter and Firebase. Fun fact: Creating the UI took the most time! However, it was really easy overall. Here is a deep dive for you! Instagram is a well-known app with hundreds of millions of users. The newsfeed with posts, likes, comments, and images is the main feature that stands out. I wanted to know what it takes to build a small app with those features. So here is how I created an Instagram clone with Flutter and Firebase. ...

March 13, 2024 · 12 min · xeladu

6 Easy Tips When Working With SetState In A Flutter Application

Introduction Follow these 6 easy tips when working with setState in a Flutter application and learn more about the mechanics of setState. Stick to the best practices to not encounter any unwanted errors. The setState function of the StatefulWidget is a simple approach to managing the state within a Flutter app. But there are several pitfalls you need to avoid when you want your app to be working and performant. Here are some best practices you should stick to. So here are 6 easy tips when working with setState in a Flutter application. ...

March 12, 2024 · 4 min · xeladu

Boost Your Flutter App Performance With These 6 Tips

Introduction Get better scrolling and animations, less memory consumption, and more execution speed. Boost your Flutter app performance with these 6 tips. And if you want more, I have a free ebook with additional tips for you at the end! Here are some easy-to-use best practices for Flutter apps when it’s all about performance. Use them if you notice any problems but don’t optimize prematurely. Flutter apps are fast by default and you won’t have any trouble usually. Here is how you can boost your Flutter app performance with these 6 tips. ...

March 12, 2024 · 4 min · xeladu

Choose the Best Data Storage Solution for Your Flutter App

Introduction Learn how to choose the best data storage solution for your Flutter app between local storage, secure storage, or a cloud database. With this guide, they won’t be any open questions about what’s the correct approach for your app! Depending of what type of app you develop, you might need different data storage solutions. In this article, I’ll introduce various options for Flutter developers of how to manage data storage in your apps. Afterwards, you will be able to choose the best data storage solution for your Flutter app. The following topics will be covered: ...

March 12, 2024 · 7 min · xeladu

How To Add A Google Map To Your Flutter App

Introduction Let’s learn how to add a Google map to your Flutter app and use location services to display the current position. Everything you need to know to get started with Google Maps in Flutter is right here! If your app relies on location data and a map, you can integrate a Google map quite easily. I’ll guide you through the setup process and show you how you can customize the map the way you want it to be. Here is how to add a Google map to your Flutter app. ...

March 12, 2024 · 5 min · xeladu

How To Create Windows Apps With Flutter

Introduction Here is a short guide on how to create Windows apps with Flutter. Learn how to build executables and MSIX packages. Use the power of Flutter Desktop and create beautiful apps for Windows! Since the release of Flutter 2.10, the Windows desktop is flagged as stable. In this article, I am going to show you what needs to be done to build executables and MSIX packages. So here is how to create Windows apps with Flutter. If you didn’t catch the news, here are the relevant sources about all the changes. ...

March 12, 2024 · 4 min · xeladu