You could create events and send a notification to the devices you want based on event type, eg. when a user likes a post, listen on insert events on that table (post_likes or whatever) and build your logic to fetch the user's device token, build your notification body and send it over.
You could create events and send a notification to the devices you want based on event type, eg. when a user likes a post, listen on
insert
events on that table (post_likes
or whatever) and build your logic to fetch the user's device token, build your notification body and send it over.