Expo Push Notifications (React Native) by https://NativeNotify.com. Send your first Expo push notification in less than a minute.
npm install native-notify
npm i native-notify
expo install expo-device expo-notifications
`$3
Import registerNNPushToken in your App.js file:
`
import registerNNPushToken from 'native-notify';
`$3
Your App.js function MUST be a hook function, or your push notifications will NOT work. Here is an example:
`
export default function App() {
...
}
`This link explains how hooks work: https://reactjs.org/docs/hooks-intro.html
$3
Paste this code into your App.js component in the App function:
`
registerNNPushToken(yourAppId, 'yourAppToken');
`
You must go to https://NativeNotify.com to receive a free App Id and App Token, or the registerNNPushToken function will not work.
It's free to sign up. No credit card required.$3
`
import registerNNPushToken from 'native-notify';export default function App() {
registerNNPushToken(yourAppId, 'yourAppToken');
return (
...
)
}
``