Currently, the firebase_cloud_messaging related logics are inside the djangoflow_app package. We need to separate the firebase_cloud_messsaging logics into a separate package.
Utility methods for checking/requesting notification permission. With optionally app_settings for rejected permission. So that user can go to the app's notification settings and enable it.
Maybe a callback too for firebase token retrieval done with the Notification listener widget. So that we can also send this token to our backend server.
The firebaseNotificationHandler widget should have callbacks, onMessage, onMessageTap
Streams need to listen to FirebaseMessaging.onMessageOpenedApp, FirebaseMessaging.onMessage.
FirebaseMessaging.instance.getInitialMessage() this we will need to call only once in app.
We need to listen to onTokenRefresh from FirebaseMessaging.
And there should a callBack which will return the token when it’s available. Even better if this callback can be triggered through a method something like DjangoflowFCMHanlder.getToken
Request notification permission through FirebaseMessaging object’s requestPermission method
Currently, the firebase_cloud_messaging related logics are inside the djangoflow_app package. We need to separate the
firebase_cloud_messsaging
logics into a separate package.The simplified purpose of this is to
Potential solution:
Bonus Task: