GoodDAPP
GoodDAPP copied to clipboard
Implement web notifications
implement web reminders via firebase
I was able to implement web notifications via Firebase. Some limitations/peculiarities
- doesn’t works on Safari.
- Next Safari version 16 on macOS may have some limited support for web push but not sure it would be enough for FCM
- Chrome shows something like ‘system’ or ‘raw’ notification firstly. It comes without GD icon (even it configured) and does nothing on click. In ~1-1.5sec service worker processes it and shows a full, clickable notification with icon . Maybe this strange behavior could be configured on FB side, need more research
- Browser should be opened (can be ran at background). Not mandatory to be focused and there’s not neccessary for the wallet app to be opened on any tab. I do not thing it’s a big issue because the swingeing majority of users aren’t closing browser :wink: they’re opening a lot of tabs and do not close them. They restart browser only when it eats almost all RAM :)
In other stuff, everything is great
- notifications received when GD site is in active tab
- notifications received when GD site is ‘in background’ e.g. non active tab
- notifications received when GD site isn’t opened on any tab
- no custom server / backend required. everything configured on the Firebase side
- easy to manage schedule
- easy to test. no need to add test flegs like send each 1minute on QA/dev, there’s a ‘send test message’ button available
we are not going to use firebase
@sirpy FCM are for free. We won’t put any confidential information there or anything should be decentralized. This is the easiest way to send scheduled notifications on the web without making own backend.
We discussed with @patpedrosa yesterday and she agreed