Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

messaging onMessage - iOS vs Android #49

Closed
Ehesp opened this issue Apr 12, 2017 · 2 comments
Closed

messaging onMessage - iOS vs Android #49

Ehesp opened this issue Apr 12, 2017 · 2 comments

Comments

@Ehesp
Copy link
Member

Ehesp commented Apr 12, 2017

Currently it would seem iOS only accepts the following to receive a remote message:

    firebase.messaging().onMessage((notification) => {

    });

Currently, Android also has on available, which doesn't work in iOS I think:

    firebase.messaging().on(firebase.messaging.EVENT_TYPE.Notification, (notification) => {

    });

Whats the correct way we should handle this cross platform?

@Salakar
Copy link
Member

Salakar commented Apr 16, 2017

@Ehesp I need to look into this, i think they should both be the same method, must've missed something during the implementation

@chrisbianca
Copy link
Contributor

onMessage works across both platforms and is the documented method as per: http://invertase.io/react-native-firebase/#/modules/cloud-messaging?id=onmessagelistener-functionltobjectgt so I'm going to close this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants