when i build i got this error 'OneSignal/OneSignal.h file not found' in RCTOneSignal.h
can i fix it?
in my fold Headers i can't find OneSignal.h
so i was reinstall and linking onesignal library in xcode
but still i have this error
even i copy onesignal.h file to my Headers folder
but i can't solve this error.
how can i fix it?
i found this issue in closed issued
but i can't add this library in cocoapod.
i successed install cocoapod. but add library failed.
how add it in cocoapod?
You need to go to your Podfile file, located within the ios folder on the root of your project.
Add the line pod 'OneSignal' as follows:
# Uncomment this line to define a global platform for your project
# platform :ios, '8.0'
# Uncomment this line if you're using Swift
# use_frameworks!
target 'YourApp' do
...
pod 'OneSignal'
end
target 'YourAppTests' do
end
Then go to terminal, go to the ios folder on the root of your project, then type pod install to install the pods. After that, make sure to drag OneSignal.framework from your Pods project on Xcode to the Frameworks folder on your Xcode workspace.
Since it's not a particular issue with the library i'm closing this now. If you have more questions, please don't hesitate.
i success install.
thx for your advices.
but i got error that "symbol(s) not found for architecture x86_64"
however i solve that error now.
https://github.com/geektimecoil/react-native-onesignal/issues/18
helpful me.
You can follow the issue you referred to solve this. Just drag the framework file to the frameworks folder and make sure it's linked on your project build phases.
i'm on react-native 0.37 and here's how i was able to get this to work (i think the readmes/documentation are slightly behind react native).
npm install react-native-onesignal --savereact-native linkimport com.geektime.reactnativeonesignal.ReactNativeOneSignalPackage; and NOT import com.geektime.rnonesignal.ReactNativeOneSignalPackage; (some old documentation had the rnonesignal and that's since been updated)YMMV if you are using something lower than v0.37 of RN. good luck.
Ran into this trying to use Auth0 with RN - posted our fix here.
$ /usr/local/bin/git clone https://github.com/CocoaPods/Specs.git master
--progress
Cloning into 'master'...
remote: Counting objects: 2114584, done.
remote: Compressing objects: 100% (386/386), done.
error: RPC failed; curl 56 SSLRead() return error -36 | 48.00 KiB/s
fatal: The remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed
[!] /usr/local/bin/git clone https://github.com/CocoaPods/Specs.git master --progress
Cloning into 'master'...
remote: Counting objects: 2114584, done.
remote: Compressing objects: 100% (386/386), done.
error: RPC failed; curl 56 SSLRead() return error -36 | 48.00 KiB/s
fatal: The remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed
Most helpful comment
You need to go to your Podfile file, located within the ios folder on the root of your project.
Add the line pod 'OneSignal' as follows:
Then go to terminal, go to the ios folder on the root of your project, then type
pod installto install the pods. After that, make sure to dragOneSignal.frameworkfrom your Pods project on Xcode to the Frameworks folder on your Xcode workspace.