Description
PushNotification.checkPermissions() does not work as it returns 'Cannot read property 'checkPermissions' of undefined'. Diving in further, require('NativeModules') does not have a PushNotificationManager which is referenced by PushNotificationIOS.js
Output of NativeModules:
Object {UIActivityIndicatorViewManager: Object, AppState: Object, LocationObserver: Object, TabBarItemManager: Object, NetworkImageViewManager: Object…}ActionSheetManager: ObjectAdSupport: ObjectAlertManager: ObjectAppState: ObjectAsyncLocalStorage: ObjectCameraRollManager: ObjectDataManager: ObjectDatePickerManager: ObjectExceptionsManager: ObjectLocationObserver: ObjectMapManager: ObjectNavItemManager: ObjectNavigatorManager: ObjectNetworkImageViewManager: ObjectPickerManager: ObjectRawTextManager: ObjectReachability: ObjectScrollViewManager: ObjectSliderManager: ObjectSourceCode: ObjectStaticImageManager: ObjectStatusBarManager: ObjectSwitchManager: ObjectTabBarItemManager: ObjectTabBarManager: ObjectTextFieldManager: ObjectTextManager: ObjectTiming: ObjectUIActivityIndicatorViewManager: ObjectUIManager: ObjectVibration: ObjectViewManager: ObjectWebViewManager: Object__proto__: Object
I've gone through the steps and enabled PushNotifications for the project.
Activity
mrdanjl commentedon Apr 1, 2015
Seems to work after manually adding the RCTPushNotificationManager.* files into xcode
jonaswindey commentedon Apr 29, 2015
Same issue here, dropping /Libraries/PushNotifcationIOS/RCTPushNotificationManager.* works.
Or otherwise you can drop RCTPushNotification.xcodeproj to /Libraries in your project.
jonaswindey commentedon Apr 29, 2015
Did you manage to get it working? I have everything up and running (Parse back-end to send push notifications) but 'PushNotificationIOS.addEventListener('notification', this._onNotification);' is never triggered.
I get the notification from iOS but not the event in the React native part. I've added a breakpoint in didReceiveRemoteNotification in RCTPushNotificationManager.m but it never halts.
brentvatne commentedon May 31, 2015
@jonaswindey - did you figure that out? ping me if not and I'll reopen