Firebase Analytics has become an indispensable tool in the world of mobile development (similar to its twin Google Analytics in the web world). And integrating it in Flutter is not the easiest task on earth. This guide covers the configuration of your Firebase project, how to integrate it with Flutter, and how to use it.
The first thing is to create a Firebase project on the Firebase console. To do so, just click on the above link. Then click on ‘Create a project.’. …
So just to make it clear, what we want to achieve today is the following behavior.
What you probably did if you already have a DateField in your Flutter project is to create it from scratch! But did you know that you could use this package to simplify your life a lot?
First, as usual, just add it to your pubspec.yaml file.
Now after a little pub get you should be able to access the package content!
First, let’s just try to display a simple DateField in our view. There are two important parameters:
When I started learning Flutter, I did not always think about canceling my stream subscription because that was something I never heard about.
But what I learned is that even if your widget is no longer alive, well, your stream subscription still is! And that can become a major issue when the widget is re-created a certain number of times, leading to possible process overload!
To prevent that, you could just add a conditional block that checks if the widget is mounted, but that would still result in a useless loss of performance.
So to prevent that here is how…
If you have an app that interacts with the outside world, you probably want to make sure that the user is connected before executing any HTTP request!
To accomplish that, we will employ the Connectivity package developed by the Flutter team.
This package is rather useful to manage the state of your app’s depending on its current internet connection!
There are two important methods and one getter for the Connectivity class:
After developing some websites and mobile app using Cordova, I got tired of HTML & CSS, I wanted something new, something that I had never tried in my entire life!
We could call it luck but not more than one month after the moment I started to look for something new, I started to work as a mobile developer for the University of Liège and I think that it won’t be a surprise for you anymore, we had to use Flutter!
In the beginning, I must say that I was not very confident about developing a complete mobile application using…
Future objects are representation of the result of an asynchronous operation that will be completed later on.
You can access the result of a Future by using the await keyword. But keep in mind that you can only use the await keyword in an asynchronous function which you declare by using the async keyword! You can specify the type of the returned value and if you do not return a concrete value you should specify the type as being void.
The Future object has very useful constructors. The default one takes an asynchronous function as an argument. …
When writing widgets with Flutter, you keep doing the same thing again again and again … After developing for over a year mobile applications with Flutter, I started to implement collections of widgets that I reuse everywhere in one or more applications. It goes from a simple custom RaisedButton to a custom Scaffold/Appbar and even up to a custom State. I compiled a list of what is most useful to do to save a lot of time while developing an application with Flutter.
The first very usefull thing to do is to create custom widgets for all the kinds of…