Skip to content
This repository was archived by the owner on Apr 4, 2023. It is now read-only.

Commit 1c17507

Browse files
#105 Firebase was unable to connect to FCM
1 parent 8bda3f9 commit 1c17507

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

docs/MESSAGING.md

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,14 @@ Open `app/App_Resources/iOS/Info.plist` and add this to the bottom:
2424
#### Provisioning hell
2525
Follow [this guide](https://firebase.google.com/docs/cloud-messaging/ios/certs) to the letter. Once you've done it run `tns run ios` and upon starting the app it should prompt you for notification support. That also works on the simulator, but actually receiving notifications is _only_ possible on a real device.
2626

27-
## Functions
28-
I tried to make this as simple as possible, so everything is handled for you transparently. If you want to act upon the notification that triggered opening your app then configure a callback handler as follows.
27+
#### Don't receive the "Allow app to receive notifications" prompt?
28+
Make sure your `app.js` has this before `application.start();`:
29+
30+
```js
31+
var firebase = require("nativescript-plugin-firebase");
32+
```
33+
34+
Delete and re-add your app after you've added this.
2935

3036
### Handling a notification
3137
To listen to received notifications while in the foreground or when your app moves from the background to the foreground, add a handler `init`.

0 commit comments

Comments
 (0)