expo-modules-core 1.4.0 → 1.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/android/CMakeLists.txt +2 -1
- package/android/build.gradle +13 -19
- package/ios/AppDelegates/ExpoAppDelegate.swift +8 -1
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -10,6 +10,12 @@
|
|
|
10
10
|
|
|
11
11
|
### 💡 Others
|
|
12
12
|
|
|
13
|
+
## 1.5.0 — 2023-06-21
|
|
14
|
+
|
|
15
|
+
### 💡 Others
|
|
16
|
+
|
|
17
|
+
- [iOS] Added Interface Geometry Management section to ExpoAppDelegate. ([#22599](https://github.com/expo/expo/pull/22599) by [@behenate](https://github.com/behenate))
|
|
18
|
+
|
|
13
19
|
## 1.4.0 — 2023-06-13
|
|
14
20
|
|
|
15
21
|
### 📚 3rd party library updates
|
package/android/CMakeLists.txt
CHANGED
|
@@ -78,7 +78,8 @@ endif ()
|
|
|
78
78
|
|
|
79
79
|
if(${UNIT_TEST})
|
|
80
80
|
if(${USE_HERMES})
|
|
81
|
-
|
|
81
|
+
find_package(hermes-engine REQUIRED CONFIG)
|
|
82
|
+
set(JSEXECUTOR_LIB hermes-engine::libhermes)
|
|
82
83
|
else()
|
|
83
84
|
set(JSEXECUTOR_LIB ReactAndroid::jscexecutor)
|
|
84
85
|
endif()
|
package/android/build.gradle
CHANGED
|
@@ -6,7 +6,7 @@ apply plugin: 'maven-publish'
|
|
|
6
6
|
apply plugin: "de.undercouch.download"
|
|
7
7
|
|
|
8
8
|
group = 'host.exp.exponent'
|
|
9
|
-
version = '1.
|
|
9
|
+
version = '1.5.0'
|
|
10
10
|
|
|
11
11
|
buildscript {
|
|
12
12
|
def expoModulesCorePlugin = new File(project(":expo-modules-core").projectDir.absolutePath, "ExpoModulesCorePlugin.gradle")
|
|
@@ -53,12 +53,12 @@ def customDownloadsDir = System.getenv("REACT_NATIVE_DOWNLOADS_DIR")
|
|
|
53
53
|
def downloadsDir = customDownloadsDir ? new File(customDownloadsDir) : new File("$buildDir/downloads")
|
|
54
54
|
def thirdPartyNdkDir = new File("$buildDir/third-party-ndk")
|
|
55
55
|
|
|
56
|
-
def REACT_NATIVE_BUILD_FROM_SOURCE = findProject(":ReactAndroid") != null
|
|
56
|
+
def REACT_NATIVE_BUILD_FROM_SOURCE = findProject(":packages:react-native:ReactAndroid") != null
|
|
57
57
|
def REACT_NATIVE_DIR = REACT_NATIVE_BUILD_FROM_SOURCE
|
|
58
|
-
? findProject(":ReactAndroid").getProjectDir().parent
|
|
58
|
+
? findProject(":packages:react-native:ReactAndroid").getProjectDir().parent
|
|
59
59
|
: new File(["node", "--print", "require.resolve('react-native/package.json')"].execute(null, rootDir).text.trim()).parent
|
|
60
60
|
def REACT_NATIVE_SO_DIR = REACT_NATIVE_BUILD_FROM_SOURCE
|
|
61
|
-
? Paths.get(findProject(":ReactAndroid").getProjectDir().toString(), "build", "intermediates", "library_*", "*", "jni")
|
|
61
|
+
? Paths.get(findProject(":packages:react-native:ReactAndroid").getProjectDir().toString(), "build", "intermediates", "library_*", "*", "jni")
|
|
62
62
|
: "${buildDir}/react/jni"
|
|
63
63
|
|
|
64
64
|
def reactProperties = new Properties()
|
|
@@ -79,26 +79,20 @@ def reactNativeArchitectures() {
|
|
|
79
79
|
def prebuiltHermesDir = findProperty("expo.prebuiltHermesDir") ?: file("${rootDir}/prebuiltHermes")
|
|
80
80
|
def prebuiltHermesVersion = file("${prebuiltHermesDir}/.hermesversion").exists() ? file("${prebuiltHermesDir}/.hermesversion").text : null
|
|
81
81
|
def currentHermesVersion = file("${REACT_NATIVE_DIR}/sdks/.hermesversion").exists() ? file("${REACT_NATIVE_DIR}/sdks/.hermesversion").text : null
|
|
82
|
-
def hasHermesProject = findProject(":ReactAndroid:hermes-engine") != null
|
|
82
|
+
def hasHermesProject = findProject(":packages:react-native:ReactAndroid:hermes-engine") != null
|
|
83
83
|
def prebuiltHermesCacheHit = hasHermesProject && currentHermesVersion == prebuiltHermesVersion
|
|
84
84
|
|
|
85
85
|
// By default we are going to download and unzip hermes inside the /sdks/hermes folder
|
|
86
86
|
// but you can provide an override for where the hermes source code is located.
|
|
87
87
|
def hermesDir = System.getenv("REACT_NATIVE_OVERRIDE_HERMES_DIR") ?: file("${REACT_NATIVE_DIR}/sdks/hermes")
|
|
88
88
|
|
|
89
|
-
def USE_HERMES =
|
|
89
|
+
def USE_HERMES = true
|
|
90
90
|
def NEED_DOWNLOAD_HERMES = false
|
|
91
91
|
def HERMES_HEADER_DIR = null
|
|
92
92
|
def HERMES_AAR = null
|
|
93
93
|
if (findProject(":app")) {
|
|
94
|
-
def
|
|
95
|
-
|
|
96
|
-
USE_HERMES = project(":app").ext.react.enableHermes
|
|
97
|
-
} else {
|
|
98
|
-
USE_HERMES = (findProperty('expo.jsEngine') ?: "jsc") == "hermes"
|
|
99
|
-
}
|
|
100
|
-
} else {
|
|
101
|
-
USE_HERMES = (findProperty('expo.jsEngine') ?: "jsc") == "hermes"
|
|
94
|
+
def appProject = project(":app")
|
|
95
|
+
USE_HERMES = appProject?.hermesEnabled?.toBoolean() || appProject?.ext?.react?.enableHermes?.toBoolean()
|
|
102
96
|
}
|
|
103
97
|
|
|
104
98
|
// Currently the needs for hermes/jsc are only for androidTest, so we turn on this flag only when `isExpoModulesCoreTests` is true
|
|
@@ -166,7 +160,7 @@ android {
|
|
|
166
160
|
targetSdkVersion safeExtGet("targetSdkVersion", 33)
|
|
167
161
|
consumerProguardFiles 'proguard-rules.pro'
|
|
168
162
|
versionCode 1
|
|
169
|
-
versionName "1.
|
|
163
|
+
versionName "1.5.0"
|
|
170
164
|
buildConfigField "boolean", "IS_NEW_ARCHITECTURE_ENABLED", isNewArchitectureEnabled.toString()
|
|
171
165
|
|
|
172
166
|
testInstrumentationRunner "expo.modules.TestRunner"
|
|
@@ -306,10 +300,10 @@ dependencies {
|
|
|
306
300
|
androidTestImplementation "org.jetbrains.kotlinx:kotlinx-coroutines-test:1.6.0"
|
|
307
301
|
|
|
308
302
|
if (USE_HERMES) {
|
|
309
|
-
def hermesProject = findProject(":ReactAndroid:hermes-engine")
|
|
310
|
-
|
|
303
|
+
def hermesProject = findProject(":packages:react-native:ReactAndroid:hermes-engine")
|
|
304
|
+
compileOnly (hermesProject ?: files(HERMES_AAR))
|
|
311
305
|
} else {
|
|
312
|
-
|
|
306
|
+
compileOnly "org.webkit:android-jsc:+"
|
|
313
307
|
}
|
|
314
308
|
}
|
|
315
309
|
|
|
@@ -415,7 +409,7 @@ afterEvaluate {
|
|
|
415
409
|
if (USE_HERMES) {
|
|
416
410
|
nativeBuildDependsOn(project, prepareHermes, null)
|
|
417
411
|
if (hasHermesProject && !prebuiltHermesCacheHit) {
|
|
418
|
-
prepareHermes.dependsOn(":ReactAndroid:hermes-engine:assembleDebug")
|
|
412
|
+
prepareHermes.dependsOn(":packages:react-native:ReactAndroid:hermes-engine:assembleDebug")
|
|
419
413
|
}
|
|
420
414
|
}
|
|
421
415
|
}
|
|
@@ -288,7 +288,14 @@ open class ExpoAppDelegate: UIResponder, UIApplicationDelegate {
|
|
|
288
288
|
|
|
289
289
|
// TODO: - Handling CloudKit Invitations
|
|
290
290
|
|
|
291
|
-
//
|
|
291
|
+
// MARK: - Managing Interface Geometry
|
|
292
|
+
|
|
293
|
+
public func application(_ application: UIApplication, supportedInterfaceOrientationsFor window: UIWindow?) -> UIInterfaceOrientationMask {
|
|
294
|
+
// We want to create an intersection of all orientations set by subscribers.
|
|
295
|
+
return subscribers.reduce(.all) { result, subscriber in
|
|
296
|
+
return subscriber.application?(application, supportedInterfaceOrientationsFor: window).intersection(result) ?? result
|
|
297
|
+
}
|
|
298
|
+
}
|
|
292
299
|
|
|
293
300
|
// MARK: - Statics
|
|
294
301
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "expo-modules-core",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.5.0",
|
|
4
4
|
"description": "The core of Expo Modules architecture",
|
|
5
5
|
"main": "build/index.js",
|
|
6
6
|
"types": "build/index.d.ts",
|
|
@@ -42,5 +42,5 @@
|
|
|
42
42
|
"@testing-library/react-hooks": "^7.0.1",
|
|
43
43
|
"expo-module-scripts": "^3.0.0"
|
|
44
44
|
},
|
|
45
|
-
"gitHead": "
|
|
45
|
+
"gitHead": "fa5ecca8251986b9f197cc14074eec0ab6dfb6db"
|
|
46
46
|
}
|