react-native-pusher-push-notifications: #import not found
Hi, first of all I would like to thank you for your hard work. I was wondering if you could help with this problem I keep having while trying to use this package. Xcode shows a #import <Pusher/Pusher.h> not found and I have the libPusher library installed with CocoaPods.
About this issue
- Original URL
- State: closed
- Created 10 years ago
- Comments: 19 (4 by maintainers)
Commits related to this issue
- Merge pull request #1 from feardarkness/feardarkness-patch-1 Allowing latest react native versions — committed to b8ne/react-native-pusher-push-notifications by feardarkness 5 years ago
- Merge pull request #1 from JordanLaing/upgrade-pusher-android bump pusher android version and build versions — committed to b8ne/react-native-pusher-push-notifications by JordanLaing 2 years ago
Hi @ahmed-wagdi sounds like a linking issue. Did you run
react-native link react-native-pusher-push-notifications?In Xcode under your Libraries you should have
RNPusherPushNotifications.xcodeprojUnder
Build Settings > Header Search Pathsyou should have$(SRCROOT)/../node_modules/react-native-pusher-push-notifications/ios (recursive)In
General > Linked Frameworks and Librariesyou should havelibRNPusherPushNotifications.a (required)And under
Build Phases > Link Binaries With Librariesyou should havelibRNPusherPushNotifications.a (required)Do you have these in your project?
Also what version of React Native are you using?
Edit: Add missing link step/screenshot
@pesakitan22 @jqn FYI version 1.0.0 has been released and is now available on npm. Both Android and iOS have been extensively tested and is currently in use in a production app, so consider this good to go.
@pesakitan22 @jqn Fixes for iOS are now in the
devbranch.npm install --save git+https://github.com/b8ne/react-native#devIf your able to, it would be awesome if you could test it out and report if it fixes the issues?
Note the setup instructions and different on this branch due to significant changes in the iOS implementation - most notably the changes to
AppDelegate.handAppDelegate.m. Just shout out on here if you need a hand getting it setup.@pesakitan22 if you are referring to the pusher native library this is a nice guide on how to do it for iOS
https://blog.brainsandbeards.com/implementing-ios-push-notifications-with-pusher-and-react-native-35e46e3565b9
I didn’t, I ended up using the pusher client api to subscribe and libpusher for iOS and pusher websocket android for android
https://pusher.com/docs/push_notifications/reference/client_api
There is a pull request you could use for android if you still want to use this library https://github.com/b8ne/react-native-pusher-push-notifications/pull/2
I haven’t tested but it might work, otherwise let me know if you need any pointers using the pusher client api.