작성
·
824
1
1-) cd ios
2-) rm -rf Podfile.lock
3-) rm -rf Pods
4-) delete .xcworkspace
5-) pod install
post_install do |installer|
installer.pods_project.targets.each do |target|
if target.name == 'React'
target.remove_from_project
end
if target.name == 'react-native-config'
phase = target.project.new(Xcodeproj::Project::Object::PBXShellScriptBuildPhase)
phase.shell_script = 'cd ../../'\
'&& RNC_ROOT=./node_modules/react-native-config/'\
'&& export SYMROOT=$RNC_ROOT/ios/ReactNativeConfig'\
'&& export BUILD_DIR=$RNC_ROOT/ios/ReactNativeConfig'\
'&& ruby $RNC_ROOT/ios/ReactNativeConfig/BuildDotenvConfig.ruby'
target.build_phases << phase
target.build_phases.move(phase,0)
end
end
end
const API_URL =
Platform.OS === 'ios'
? 'http://localhost:3105'
: 'http://10.0.2.2:3105';
console.log(API_URL);
const response = await axios.post(`${API_URL}/login`, {
email,
password,
});