Comments (4)
@szymonrybczak I have open a PR with some suggestions which could fix the mentioned issue (#2341).
from cli.
hey @AlexanderEggers, as of my knowledge there's no unfortunately. I'll try to find a way to set this path correctly.
from cli.
hey @AlexanderEggers, can you please try setting projectDir
through settings.gradle
?
diff --git a/my_wraper/android/gradlew b/my_wraper/android/gradlew
old mode 100644
new mode 100755
diff --git a/my_wraper/android/settings.gradle b/my_wraper/android/settings.gradle
index 9694a74..f3259bf 100644
--- a/my_wraper/android/settings.gradle
+++ b/my_wraper/android/settings.gradle
@@ -1,4 +1,5 @@
rootProject.name = 'AwesomeProject'
+rootProject.projectDir = new File(rootProject.projectDir, "../reactnativemodule")
apply from: file("../reactnativemodule/node_modules/@react-native-community/cli-platform-android/native_modules.gradle"); applyNativeModulesSettingsGradle(settings)
include ':app'
includeBuild('../reactnativemodule/node_modules/@react-native/gradle-plugin')
from cli.
@szymonrybczak Thanks for your suggestion but I'm not certain if that is what would make sense in this case. The base Android project still needs to be compiled and is indeed the root project. The missing option is to define the RN root project so that the native modules gradle file resolves correctly.
Something like injecting a custom path as part of this line file("../node_modules/@react-native-community/cli-platform-android/native_modules.gradle"); applyNativeModulesAppBuildGradle(project)
.
from cli.
Related Issues (20)
- Support for javascript template when initialize latest React Native HOT 1
- How can I get cli-platform-ios to recognize my M1-based Mac as a Destination/target-device?
- 🚨 Security Vulnerability: ip npm package is unsafe for use as of v1.1.8 HOT 21
- Could not create an empty Git repository, see debug logs with --verbose HOT 14
- Unable to start server in new window when using yarn with pnpm linker HOT 2
- FAILURE: Build failed with an exception.
- FAILURE: Build failed with an exception. Script '/home/xyz/Documents/CQ/projectName/node_modules/@react-native-community/cli-platform-android/native_modules.gradle' line: 375 HOT 1
- Implement support for Android activity aliases
- Not possible to specify macCatalyst UDID as run target
- Passing registry for different package managers HOT 5
- Health Check Plugin isn't executed when running `react-native doctor` HOT 2
- react-native run-android: Failed to install the app on the device. Error: Could not find the correct install APK file.
- How to build android release but with JS dev flag enabled?
- On Android, app isn't opened automatically if applicationId is changed HOT 1
- API not working in React native android but working in ios. HOT 1
- Can CRNA change name inside project like NPX react-native init? HOT 1
- ✖ Could not create an empty Git repository, see debug logs with --verbose HOT 2
- Execution failed for task ':app:buildCMakeDebug[x86]' HOT 4
- Stuck at info JS server already running on Linux 22.04 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cli.