Skip to content

Commit 9de82d3

Browse files
authored
fix(ios, expo): add Expo plugin objcpp / Expo 45 compatibility (#6223)
1 parent 0fd4b4f commit 9de82d3

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

packages/app/plugin/__tests__/__snapshots__/iosPlugin.test.ts.snap

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ exports[`Config Plugin iOS Tests tests changes made to AppDelegate.m (SDK 43) 1`
66
// creating a bare React Native app (without Expo)
77
88
#import \\"AppDelegate.h\\"
9-
@import Firebase;
9+
#import <Firebase/Firebase.h>
1010
1111
#import <React/RCTBridge.h>
1212
#import <React/RCTBundleURLProvider.h>
@@ -99,7 +99,7 @@ exports[`Config Plugin iOS Tests tests changes made to AppDelegate.m with Expo R
9999
// It has the RCTBridge to be created by Expo ReactDelegate
100100
101101
#import \\"AppDelegate.h\\"
102-
@import Firebase;
102+
#import <Firebase/Firebase.h>
103103
104104
#import <React/RCTBridge.h>
105105
#import <React/RCTBundleURLProvider.h>
@@ -189,7 +189,7 @@ exports[`Config Plugin iOS Tests tests changes made to AppDelegate.m with fallba
189189
// some parts omitted to be short
190190
191191
#import \\"AppDelegate.h\\"
192-
@import Firebase;
192+
#import <Firebase/Firebase.h>
193193
194194
#import <React/RCTBridge.h>
195195
#import <React/RCTBundleURLProvider.h>
@@ -240,7 +240,7 @@ exports[`Config Plugin iOS Tests tests changes made to old AppDelegate.m (SDK 42
240240
// It expects the old react-native-unimodules architecture (UM* prefix)
241241
242242
#import \\"AppDelegate.h\\"
243-
@import Firebase;
243+
#import <Firebase/Firebase.h>
244244
245245
#import <React/RCTBridge.h>
246246
#import <React/RCTBundleURLProvider.h>
@@ -351,7 +351,7 @@ exports[`Config Plugin iOS Tests works with AppDelegate.mm (RN 0.68+) 1`] = `
351351
// using React Native 0.68 and is written in Objective-C++
352352
353353
#import \\"AppDelegate.h\\"
354-
@import Firebase;
354+
#import <Firebase/Firebase.h>
355355
356356
#import <React/RCTBridge.h>
357357
#import <React/RCTBundleURLProvider.h>

packages/app/plugin/src/ios/appDelegate.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ export function modifyObjcAppDelegate(contents: string): string {
1919
contents = contents.replace(
2020
/#import "AppDelegate.h"/g,
2121
`#import "AppDelegate.h"
22-
@import Firebase;`,
22+
#import <Firebase/Firebase.h>`,
2323
);
2424
}
2525

0 commit comments

Comments
 (0)