0

If the application is in the foreground I am able to customize the notification though I read when app is backgrounded. The FCM handles the notifications by default(Does that mean we can not customize those notifications?)

AL.
  • 36,815
  • 10
  • 142
  • 281
Alisha
  • 1
  • 4

1 Answers1

0

By default you will receive:

"notification":{
     "title": "Awesome notif!",
     "body": "Test notif"
 }

This one will be handle only when you're in foreground.

if you send:

"data":{
     "title": "Awesome notif!",
     "body": "Test notif"
 },

it will be handle by both background and foreground.

I highly recommend you to read this article it explains everything you have to know about that.

agonist_
  • 4,890
  • 6
  • 32
  • 55