Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions packages/rn-tester/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -226,11 +226,12 @@ dependencies {
// Build React Native from source
implementation project(':ReactAndroid')

implementation "androidx.swiperefreshlayout:swiperefreshlayout:1.0.0"
// Consume Hermes as built from source only for the Hermes variant.
hermesImplementation(project(":ReactAndroid:hermes-engine")) {
exclude group:'com.facebook.fbjni'
}

def hermesPath = '$projectDir/../../../../../node_modules/hermes-engine/android/'
hermesDebugImplementation files(hermesPath + "hermes-debug.aar")
hermesReleaseImplementation files(hermesPath + "hermes-release.aar")
implementation "androidx.swiperefreshlayout:swiperefreshlayout:1.0.0"

debugImplementation("com.facebook.flipper:flipper:${FLIPPER_VERSION}") {
exclude group:'com.facebook.fbjni'
Expand Down
13 changes: 9 additions & 4 deletions template/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -271,9 +271,10 @@ dependencies {
}

if (enableHermes) {
def hermesPath = "../../node_modules/hermes-engine/android/";
debugImplementation files(hermesPath + "hermes-debug.aar")
releaseImplementation files(hermesPath + "hermes-release.aar")
//noinspection GradleDynamicVersion
implementation("com.facebook.react:hermes-engine:+") { // From node_modules
exclude group:'com.facebook.fbjni'
}
} else {
implementation jscFlavor
}
Expand All @@ -286,7 +287,11 @@ if (isNewArchitectureEnabled()) {
configurations.all {
resolutionStrategy.dependencySubstitution {
substitute(module("com.facebook.react:react-native"))
.using(project(":ReactAndroid")).because("On New Architecture we're building React Native from source")
.using(project(":ReactAndroid"))
.because("On New Architecture we're building React Native from source")
substitute(module("com.facebook.react:hermes-engine"))
.using(project(":ReactAndroid:hermes-engine"))
.because("On New Architecture we're building Hermes from source")
}
}
}
Expand Down
2 changes: 2 additions & 0 deletions template/android/settings.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,6 @@ includeBuild('../node_modules/react-native-gradle-plugin')
if (settings.hasProperty("newArchEnabled") && settings.newArchEnabled == "true") {
include(":ReactAndroid")
project(":ReactAndroid").projectDir = file('../node_modules/react-native/ReactAndroid')
include(":ReactAndroid:hermes-engine")
project(":ReactAndroid:hermes-engine").projectDir = file('../node_modules/react-native/ReactAndroid/hermes-engine')
Comment on lines +9 to +10
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice ^ spotted/fixed in the nightly too earlier

but lagging few days behind 🤪 more contributions inc

}