On the root of your Flutter project, run the following command to install the plugin:
Read moreHow do you handle notifications on Flutter?
To handle push notifications we are going to create a separate class . This class will initialize the FirebaseMessaging object, whose functions will be used to handle push notifications. Call this class from the initial widget’s initState() method so that we can initialize the FirebaseMessaging at the start.
Read more