Notifications working
This commit is contained in:
2
App.js
2
App.js
@@ -52,7 +52,7 @@ async function registerForPushNotificationsAsync() {
|
|||||||
alert('Failed to get push token for push notification!');
|
alert('Failed to get push token for push notification!');
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
token = (await Notifications.getExpoPushTokenAsync()).data;
|
token = (await Notifications.getExpoPushTokenAsync({ projectId: "c2bb4d4e-4d4d-4f34-a873-7cad78c6023c", })).data;
|
||||||
console.log(token);
|
console.log(token);
|
||||||
} else {
|
} else {
|
||||||
alert('Must use physical device for Push Notifications');
|
alert('Must use physical device for Push Notifications');
|
||||||
|
|||||||
13
app.json
13
app.json
@@ -25,7 +25,8 @@
|
|||||||
"foregroundImage": "./assets/icon.png",
|
"foregroundImage": "./assets/icon.png",
|
||||||
"backgroundColor": "#FFFFFF"
|
"backgroundColor": "#FFFFFF"
|
||||||
},
|
},
|
||||||
"package": "com.emi.social"
|
"package": "com.emi.social",
|
||||||
|
"googleServicesFile": "./google-services.json"
|
||||||
},
|
},
|
||||||
"web": {
|
"web": {
|
||||||
"favicon": "./assets/favicon.png"
|
"favicon": "./assets/favicon.png"
|
||||||
@@ -37,15 +38,7 @@
|
|||||||
},
|
},
|
||||||
"plugins": [
|
"plugins": [
|
||||||
[
|
[
|
||||||
"expo-notifications",
|
"expo-notifications"
|
||||||
{
|
|
||||||
"icon": "./local/assets/notification-icon.png",
|
|
||||||
"color": "#ffffff",
|
|
||||||
"sounds": [
|
|
||||||
"./local/assets/notification-sound.wav",
|
|
||||||
"./local/assets/notification-sound-other.wav"
|
|
||||||
]
|
|
||||||
}
|
|
||||||
]
|
]
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
8440
package-lock.json
generated
8440
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@@ -11,6 +11,7 @@
|
|||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@react-native-async-storage/async-storage": "~1.17.3",
|
"@react-native-async-storage/async-storage": "~1.17.3",
|
||||||
|
"@react-native-firebase/app": "^16.4.6",
|
||||||
"@react-navigation/bottom-tabs": "^6.2.0",
|
"@react-navigation/bottom-tabs": "^6.2.0",
|
||||||
"@react-navigation/native": "^6.0.8",
|
"@react-navigation/native": "^6.0.8",
|
||||||
"@react-navigation/native-stack": "^6.5.0",
|
"@react-navigation/native-stack": "^6.5.0",
|
||||||
@@ -26,7 +27,6 @@
|
|||||||
"moment": "^2.29.1",
|
"moment": "^2.29.1",
|
||||||
"react": "18.1.0",
|
"react": "18.1.0",
|
||||||
"react-dom": "18.1.0",
|
"react-dom": "18.1.0",
|
||||||
"react-google-material-icons": "^1.0.4",
|
|
||||||
"react-native": "0.70.5",
|
"react-native": "0.70.5",
|
||||||
"react-native-autoheight-webview": "^1.6.1",
|
"react-native-autoheight-webview": "^1.6.1",
|
||||||
"react-native-hyperlink": "0.0.19",
|
"react-native-hyperlink": "0.0.19",
|
||||||
|
|||||||
Reference in New Issue
Block a user