You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After each failed attempt, I deleted the iOS platform folder and recreated it using ionic capacitor add ios to be able to redo the attempts in a completely clean code and thus avoid possible conflicts, but I always get the same problem.
These are exactly the steps I'm doing:
ionic capacitor add ios (recreating the iOS project after deleting it)
xed ios/App (in Capacitor 4 this is the project structure)
Enable Push Notifications and Remote Notifications (inside of Background Modes) in Signing & Capabilities
Go to File > New > Target..., insert the name OneSignalNotificationServiceExtension, select Objective-C as language and then click on Finish and then Cancel
With OneSignalNotificationServiceExtension selected in the target list, I select the Deployment Target as iOS 13 (just like I'm using in the Main Application Target)
Open the NotificationService.m file inside the newly created OneSignalNotificationServiceExtension folder and then replace all its contents with Objective-C code
Select the OneSignalNotificationServiceExtension target, enter the Build Settings tab and make sure that the values of Debug and Release within Code Signing Entitlements are already blank
Close Xcode
Open ios/App/Podfile
Include the following code at the end of Podfile:
target 'OneSignalNotificationServiceExtension' do
pod 'OneSignalXCFramework', '>= 3.0.0', '< 4.0'
end
Return to the terminal and then pod repo update and pod install, which returns the following:
Analyzing dependencies
Downloading dependencies
Installing OneSignalXCFramework 3.12.3
Generating Pods project
Integrating client project
Pod installation complete! There are 23 dependencies from the Podfile and 33 total pods installed.
xed ios/App and wait for Xcode to open and index files
Keep getting the error 'OneSignal/OneSignal.h' file not found
How can we help?
I'm migrating my Ionic + Capacitor 2 app to Capacitor 4 but I'm having trouble configuring the iOS Service Extensions using OneSignal.
I'm following all the steps described in https://documentation.onesignal.com/docs/ionic-sdk-setup#step-5-configure-your-xcode-project-ios-only however, Xcode always shows the error
'OneSignal/OneSignal.h' file not found
.After each failed attempt, I deleted the iOS platform folder and recreated it using
ionic capacitor add ios
to be able to redo the attempts in a completely clean code and thus avoid possible conflicts, but I always get the same problem.These are exactly the steps I'm doing:
ionic capacitor add ios
(recreating the iOS project after deleting it)xed ios/App
(in Capacitor 4 this is the project structure)Push Notifications
andRemote Notifications
(inside ofBackground Modes
) inSigning & Capabilities
File > New > Target...
, insert the nameOneSignalNotificationServiceExtension
, selectObjective-C
as language and then click onFinish
and thenCancel
OneSignalNotificationServiceExtension
selected in the target list, I select theDeployment Target
as iOS 13 (just like I'm using in theMain Application Target
)NotificationService.m
file inside the newly createdOneSignalNotificationServiceExtension
folder and then replace all its contents with Objective-C codeOneSignalNotificationServiceExtension
target, enter theBuild Settings
tab and make sure that the values ofDebug
andRelease
withinCode Signing Entitlements
are already blankios/App/Podfile
Podfile
:pod repo update
andpod install
, which returns the following:xed ios/App
and wait for Xcode to open and index files'OneSignal/OneSignal.h' file not found
As I already said I've followed every single step in https://documentation.onesignal.com/docs/ionic-sdk-setup#step-5-configure-your-xcode-project-ios-only and redone these steps numerous times until I came to the conclusion that I didn't make any mistakes and followed all the steps as recommended, so how can I resolve this?
Thanks!
Code of Conduct
The text was updated successfully, but these errors were encountered: