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

Add userInteraction attr for user opened push #122

Merged

Conversation

xvonabur
Copy link
Contributor

Summary

In my app I need to run some JS code after user clicked on local notification. I didn't find any way to determine the moment user clicked on it.
This PR adds additional userInteraction attribute to userInfo for push messages that was opened by user.

If somebody approve this changes, I'll add an example.

Compatibility

OS Implemented
iOS ✅❌
Android ✅❌

@TaraSinghDanu
Copy link

TaraSinghDanu commented Jul 22, 2020

Not working...Always getting false

Copy link
Contributor

@Dallas62 Dallas62 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this PR, this is an awesome fix for the community, I have only one change to request from my tests 😉

ios/RNCPushNotificationIOS.m Outdated Show resolved Hide resolved
@nishanttatva
Copy link

@Dallas62 @xvonabur
ETA when this will be merged?

@Dallas62
Copy link
Contributor

Hi @nishanttatva
We are not able to merge, so the answer is no 😉

@xvonabur
Copy link
Contributor Author

@Dallas62 I've added requested changes. Feel free to review it again.

Copy link
Contributor

@Dallas62 Dallas62 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Dallas62
Copy link
Contributor

@Naturalclar It would be great if you find time to look at this PR 😉

@Naturalclar
Copy link
Collaborator

@Dallas62 thanks for the ping! I'll take a look at it soon

Copy link
Collaborator

@Naturalclar Naturalclar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@xvonabur Thank you! The change looks good to me.
Would you be able to add an example usage in the README and example?

@xvonabur
Copy link
Contributor Author

@Naturalclar I've added example and information to README. Can you check it?

@Naturalclar Naturalclar merged commit 0d951d3 into react-native-push-notification:master Sep 12, 2020
@Naturalclar
Copy link
Collaborator

@xvonabur thank you for the change! I've published 1.5.0 with the new feature 🎉

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

Successfully merging this pull request may close these issues.

None yet

5 participants