Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[question]: Expo dependency for iOS Notification Service Extension Module #1476

Closed
1 task done
d-podabed-belitsoft-com opened this issue Jan 6, 2023 · 2 comments
Closed
1 task done
Assignees

Comments

@d-podabed-belitsoft-com
Copy link

d-podabed-belitsoft-com commented Jan 6, 2023

How can we help?

Hello. In "iOS Notification Service Extension Module" guide (https://documentation.onesignal.com/docs/rn-android-native-module-setup-for-notification-service-extension#ios-notification-service-extension-module) in step "Sending Events to Javascript" (https://documentation.onesignal.com/docs/rn-android-native-module-setup-for-notification-service-extension#sending-events-to-javascript-1) added this line #import <EXUpdates/EXUpdatesAppController.h> to AppDelegate.h file. And 'cause of that build corrupted. And before no Expo in previous steps. Is it possible to make it work without EXUpdatesAppController.h? I tried to install expo-updates manually (via Expo guide). No result. I found related issue #1375, but not helped for me too (in it just excluded AppDelegate.h modification, build works, but without background pushes).

Code of Conduct

  • I agree to follow this project's Code of Conduct
@brismithers
Copy link

Thank you for the feedback @d-podabed-belitsoft-com . I believe the documentation is in error and assumes an Expo app, when it should not.

You should be able to remove the #import <EXUpdates/EXUpdatesAppControllerh> line, as well as the reference to EXUpdatesAppControllerDelegate in your AppDelegate interface declaration. So your AppDelegate.h file should look something like this:

#import <Foundation/Foundation.h>
#import <React/RCTBridgeDelegate.h>
#import <UIKit/UIKit.h>

#import <UserNotifications/UserNotifications.h>


#import <UMCore/UMAppDelegateWrapper.h>

@interface AppDelegate : UMAppDelegateWrapper <UIApplicationDelegate, RCTBridgeDelegate>


@end

with your AppDelegate.m file implementing the didReceiveRemoteNotification method as specified in the doc.

Please confirm this as a solution and I will make the doc update as well. Thanks!

@brismithers brismithers self-assigned this Jan 23, 2023
@brismithers
Copy link

Hi @d-podabed-belitsoft-com just checking in, did the above suggestion resolve your issue? Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants