-
Notifications
You must be signed in to change notification settings - Fork 909
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Unable to specify sourceDir for iOS in react-native.config.js #1548
Comments
Did a bit of digging into the CLI source code... It looks like for a custom Android project location you'd use module.exports = {
project: {
android: {
sourceDir: './custom-android-location',
},
ios: {
project: './custom-ios-location/ios/YourIOSProject.xcodeproj',
},
},
}; Not sure whether this inconsistency is intentional (if so we should update the documentation)? Or is this a bug? |
I think this issue is now fixed, but on my end I had to use the following code because relative
I'm not sure if it's an issue with |
Hopefully this should work for you: |
There hasn't been any activity on this issue in the past 3 months, so it has been marked as stale and it will be closed automatically if no further activity occurs in the next 7 days. |
Environment
Description
I have a project that contains multiple iOS apps. The React Native CLI is selecting the incorrect iOS project, so I'm trying to specify a
project.ios.sourceDir
in myreact-native.config.js
as per the CLI docs, but this is leading to thenpx react-native config
command failing with the following error...Reproducible Demo
ios/
folder tocustom-ios-location/
react-native.config.js
file at the root of the projectExpected: RN CLI prints the project native linking configuration using the provided location for the iOS project.
Actual: RN CLI fails to print configuration and instead gives a
"Config Validation Error: "project.ios.sourceDir"
is not allowed" errorThe text was updated successfully, but these errors were encountered: