Meteor-Community-Packages / raix-push

DEPRECATED: Push notifications for cordova (ios, android) browser (Chrome, Safari, Firefox)
https://atmospherejs.com/raix/push
MIT License
514 stars 197 forks source link

Action Buttons and click event on a message #335

Open atomoc opened 6 years ago

atomoc commented 6 years ago

@raix hi! Explain please. When sending a message, you need to specify what to do when clicking on the message. I understand this is implemented in the phonegap-plugin-push, but how can I achieve this here? Perhaps via Meteor.call or Push.on... In this case, it is necessary that the parameters be transmitted - this is very necessary.

atomoc commented 6 years ago

A simple opening of the application is not suitable.

atomoc commented 6 years ago

Also this topic was touched on the forum meteor.

raix commented 6 years ago

Hi @atomoc I've answered this question before (getting too old to remember where)

So there are two types of notifications:

Now if the app is closed thats the easy case cause the os will take care of things.

If the app is open if would be pretty bad UX if the native notifications interrupted the user - that's where you come in... You have to handle the notifications when the app is open in a nice user friendly way - there is no single solution to it.

If you want to actually trigger a native notification then use the local notification system - there is a cordova plugin for it

atomoc commented 6 years ago

It is important that this works when the application is closed. Cordova plugin is not suitable, because js does not work when the application is closed.

It is necessary for Push to handle the events that occur when you click on the notification (for example), is it really unrealistic?

In the future, I will most likely transfer the application to the React Native..., I just do not believe that this plug-in is not capable of it.

Just say, is it capable or not? I'm just tired of beating my head against the wall )