Good afternoon. Write an application (chat) on react native. Notification should be sent to the phone and to count the number of unread messages. I Sobieraj when leaving a person to remember the number of the last message and using firebase functions to hang up the handler which will increase the number of not read messages. and every time it will increase the number of presales want soobsenie on the phone. Want to use firebase functions.
The question is whether the logic and whether there are simpler ways to solve these problems?