diff --git a/apps/app/.gitignore b/apps/app/.gitignore index d5ae456..5881adf 100644 --- a/apps/app/.gitignore +++ b/apps/app/.gitignore @@ -72,3 +72,5 @@ yarn-error.log !.yarn/releases !.yarn/sdks !.yarn/versions + +ios/tmp.xcconfig diff --git a/apps/app/android/app/build.gradle b/apps/app/android/app/build.gradle index f91df82..3158be1 100644 --- a/apps/app/android/app/build.gradle +++ b/apps/app/android/app/build.gradle @@ -1,4 +1,5 @@ apply plugin: "com.android.application" +apply from: project(':react-native-config').projectDir.getPath() + "/dotenv.gradle" apply plugin: "org.jetbrains.kotlin.android" apply plugin: "com.facebook.react" @@ -110,6 +111,7 @@ android { dependencies { // The version of react-native is set by the React Native Gradle Plugin implementation("com.facebook.react:react-android") + implementation project(':react-native-config') if (hermesEnabled.toBoolean()) { implementation("com.facebook.react:hermes-android") diff --git a/apps/app/android/app/src/main/java/com/app/MainApplication.kt b/apps/app/android/app/src/main/java/com/app/MainApplication.kt index 9e7449e..2e6d762 100644 --- a/apps/app/android/app/src/main/java/com/app/MainApplication.kt +++ b/apps/app/android/app/src/main/java/com/app/MainApplication.kt @@ -11,6 +11,7 @@ import com.facebook.react.defaults.DefaultReactHost.getDefaultReactHost import com.facebook.react.defaults.DefaultReactNativeHost import com.facebook.react.soloader.OpenSourceMergedSoMapping import com.facebook.soloader.SoLoader +import com.lugg.RNCConfig.RNCConfigPackage class MainApplication : Application(), ReactApplication { @@ -20,6 +21,7 @@ class MainApplication : Application(), ReactApplication { PackageList(this).packages.apply { // Packages that cannot be autolinked yet can be added manually here, for example: // add(MyReactNativePackage()) + add(RNCConfigPackage()) } override fun getJSMainModuleName(): String = "index" diff --git a/apps/app/android/settings.gradle b/apps/app/android/settings.gradle index ebc000a..5ca35aa 100644 --- a/apps/app/android/settings.gradle +++ b/apps/app/android/settings.gradle @@ -5,3 +5,5 @@ rootProject.name = 'fienmee-app' include ':app' includeBuild('../node_modules/@react-native/gradle-plugin') +include ':react-native-config' +project(':react-native-config').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-config/android') diff --git a/apps/app/ios/Config.xcconfig b/apps/app/ios/Config.xcconfig new file mode 100644 index 0000000..e81b53c --- /dev/null +++ b/apps/app/ios/Config.xcconfig @@ -0,0 +1,10 @@ +// +// Config.xcconfig +// app +// +// Created by 나구원 on 12/13/24. +// + +// Configuration settings file format documentation can be found at: +// https://help.apple.com/xcode/#/dev745c5c974 +#include? "tmp.xcconfig" diff --git a/apps/app/ios/Podfile.lock b/apps/app/ios/Podfile.lock index 3578101..0326708 100644 --- a/apps/app/ios/Podfile.lock +++ b/apps/app/ios/Podfile.lock @@ -1242,6 +1242,10 @@ PODS: - ReactCommon/turbomodule/bridging - ReactCommon/turbomodule/core - Yoga + - react-native-config (1.5.3): + - react-native-config/App (= 1.5.3) + - react-native-config/App (1.5.3): + - React-Core - react-native-safe-area-context (4.14.0): - DoubleConversion - glog @@ -1682,6 +1686,7 @@ DEPENDENCIES: - React-logger (from `../node_modules/react-native/ReactCommon/logger`) - React-Mapbuffer (from `../node_modules/react-native/ReactCommon`) - React-microtasksnativemodule (from `../node_modules/react-native/ReactCommon/react/nativemodule/microtasks`) + - react-native-config (from `../node_modules/react-native-config`) - react-native-safe-area-context (from `../node_modules/react-native-safe-area-context`) - react-native-webview (from `../node_modules/react-native-webview`) - React-nativeconfig (from `../node_modules/react-native/ReactCommon`) @@ -1790,6 +1795,8 @@ EXTERNAL SOURCES: :path: "../node_modules/react-native/ReactCommon" React-microtasksnativemodule: :path: "../node_modules/react-native/ReactCommon/react/nativemodule/microtasks" + react-native-config: + :path: "../node_modules/react-native-config" react-native-safe-area-context: :path: "../node_modules/react-native-safe-area-context" react-native-webview: @@ -1889,6 +1896,7 @@ SPEC CHECKSUMS: React-logger: 81d58ca6f1d93fca9a770bda6cc1c4fbfcc99c9c React-Mapbuffer: 726951e68f4bb1c2513d322f2548798b2a3d628d React-microtasksnativemodule: 7a69a9b8fded72ea3cf81923ecf75cad5558ed26 + react-native-config: 8f7283449bbb048902f4e764affbbf24504454af react-native-safe-area-context: 2500e4fe998caad50ad3bc51ec23ef951308569e react-native-webview: 0bd56be54d01756f20eb942dad37a2cd22a6def2 React-nativeconfig: 470fce6d871c02dc5eff250a362d56391b7f52d6 diff --git a/apps/app/ios/app.xcodeproj/project.pbxproj b/apps/app/ios/app.xcodeproj/project.pbxproj index cf843be..dfd3db9 100644 --- a/apps/app/ios/app.xcodeproj/project.pbxproj +++ b/apps/app/ios/app.xcodeproj/project.pbxproj @@ -40,6 +40,7 @@ 13B07FB81A68108700A75B9A /* PrivacyInfo.xcprivacy */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = PrivacyInfo.xcprivacy; path = app/PrivacyInfo.xcprivacy; sourceTree = ""; }; 19F6CBCC0A4E27FBF8BF4A61 /* libPods-app-appTests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-app-appTests.a"; sourceTree = BUILT_PRODUCTS_DIR; }; 3B4392A12AC88292D35C810B /* Pods-app.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-app.debug.xcconfig"; path = "Target Support Files/Pods-app/Pods-app.debug.xcconfig"; sourceTree = ""; }; + 5190EDF22D0C688D00DC5D68 /* Config.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = Config.xcconfig; sourceTree = ""; }; 5709B34CF0A7D63546082F79 /* Pods-app.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-app.release.xcconfig"; path = "Target Support Files/Pods-app/Pods-app.release.xcconfig"; sourceTree = ""; }; 5B7EB9410499542E8C5724F5 /* Pods-app-appTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-app-appTests.debug.xcconfig"; path = "Target Support Files/Pods-app-appTests/Pods-app-appTests.debug.xcconfig"; sourceTree = ""; }; 5DCACB8F33CDC322A6C60F78 /* libPods-app.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-app.a"; sourceTree = BUILT_PRODUCTS_DIR; }; @@ -119,6 +120,7 @@ 83CBB9F61A601CBA00E9B192 = { isa = PBXGroup; children = ( + 5190EDF22D0C688D00DC5D68 /* Config.xcconfig */, 13B07FAE1A68108700A75B9A /* app */, 832341AE1AAA6A7D00B99B32 /* Libraries */, 00E356EF1AD99517003FC87E /* appTests */, @@ -519,6 +521,7 @@ }; 83CBBA201A601CBA00E9B192 /* Debug */ = { isa = XCBuildConfiguration; + baseConfigurationReference = 5190EDF22D0C688D00DC5D68 /* Config.xcconfig */; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; @@ -599,6 +602,7 @@ }; 83CBBA211A601CBA00E9B192 /* Release */ = { isa = XCBuildConfiguration; + baseConfigurationReference = 5190EDF22D0C688D00DC5D68 /* Config.xcconfig */; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; diff --git a/apps/app/ios/app.xcodeproj/xcshareddata/xcschemes/app.xcscheme b/apps/app/ios/app.xcodeproj/xcshareddata/xcschemes/app.xcscheme index 9b78d17..26540ec 100644 --- a/apps/app/ios/app.xcodeproj/xcshareddata/xcschemes/app.xcscheme +++ b/apps/app/ios/app.xcodeproj/xcshareddata/xcschemes/app.xcscheme @@ -1,10 +1,28 @@ + version = "1.7"> + + + + + + + + + + { - return + return }} /> =0.61' + peerDependenciesMeta: + react-native-windows: + optional: true + react-native-safe-area-context@4.14.0: resolution: {integrity: sha512-/SyYpCulWQOnnXhRq6wepkhoyQMowHm1ptDyRz20s+YS/R9mbd+mK+jFyFCyXFJn8jp7vFl43VUCgspuOiEbwA==} peerDependencies: @@ -12323,6 +12334,8 @@ snapshots: react-is@18.3.1: {} + react-native-config@1.5.3: {} + react-native-safe-area-context@4.14.0(react-native@0.76.2(@babel/core@7.26.0)(@babel/preset-env@7.26.0(@babel/core@7.26.0))(@react-native-community/cli-server-api@15.1.2)(@types/react@18.3.12)(react@18.3.1))(react@18.3.1): dependencies: react: 18.3.1