Ios 将react本机版本0.59更新为0.60后生成Pod文件问题
我已将react本机版本Ios 将react本机版本0.59更新为0.60后生成Pod文件问题,ios,react-native,cocoapods,Ios,React Native,Cocoapods,我已将react本机版本0.59.9更新为0.60.5 版本之前: "react": "16.8.3", "react-native": "0.59.9", "react": "16.8.6", "react-native": "0.60.5", 更新版本后: "react": "16.8.3", "react-native": "0.59.9", "react": "16.8.6", "react-native": "0.60.5", 更新版本后,在iOS目录中,无法看到pod文件。
0.59.9
更新为0.60.5
版本之前:
"react": "16.8.3",
"react-native": "0.59.9",
"react": "16.8.6",
"react-native": "0.60.5",
更新版本后:
"react": "16.8.3",
"react-native": "0.59.9",
"react": "16.8.6",
"react-native": "0.60.5",
更新版本后,在iOS
目录中,无法看到pod文件。
因此,我运行了以下命令来生成pod
文件
pod init
pod install
应用命令后,我可以看到我的pod文件,如下所示
# Uncomment the next line to define a global platform for your project
# platform :ios, '9.0'
target 'Base' do
# Uncomment the next line if you're using Swift or would like to use dynamic frameworks
# use_frameworks!
# Pods for Base
target 'BaseTests' do
inherit! :search_paths
# Pods for testing
end
end
但当我们创建一个新项目时,我们可以默认地使用pods获得以下pod文件
platform :ios, '9.0'
require_relative '../node_modules/@react-native-community/cli-platform-ios/native_modules'
target 'Temp' do
# Pods for Temp
pod 'React', :path => '../node_modules/react-native/'
pod 'React-Core', :path => '../node_modules/react-native/React'
pod 'React-DevSupport', :path => '../node_modules/react-native/React'
pod 'React-RCTActionSheet', :path => '../node_modules/react-native/Libraries/ActionSheetIOS'
pod 'React-RCTAnimation', :path => '../node_modules/react-native/Libraries/NativeAnimation'
pod 'React-RCTBlob', :path => '../node_modules/react-native/Libraries/Blob'
pod 'React-RCTImage', :path => '../node_modules/react-native/Libraries/Image'
pod 'React-RCTLinking', :path => '../node_modules/react-native/Libraries/LinkingIOS'
pod 'React-RCTNetwork', :path => '../node_modules/react-native/Libraries/Network'
pod 'React-RCTSettings', :path => '../node_modules/react-native/Libraries/Settings'
pod 'React-RCTText', :path => '../node_modules/react-native/Libraries/Text'
pod 'React-RCTVibration', :path => '../node_modules/react-native/Libraries/Vibration'
pod 'React-RCTWebSocket', :path => '../node_modules/react-native/Libraries/WebSocket'
pod 'React-cxxreact', :path => '../node_modules/react-native/ReactCommon/cxxreact'
pod 'React-jsi', :path => '../node_modules/react-native/ReactCommon/jsi'
pod 'React-jsiexecutor', :path => '../node_modules/react-native/ReactCommon/jsiexecutor'
pod 'React-jsinspector', :path => '../node_modules/react-native/ReactCommon/jsinspector'
pod 'yoga', :path => '../node_modules/react-native/ReactCommon/yoga'
pod 'DoubleConversion', :podspec => '../node_modules/react-native/third-party-podspecs/DoubleConversion.podspec'
pod 'glog', :podspec => '../node_modules/react-native/third-party-podspecs/glog.podspec'
pod 'Folly', :podspec => '../node_modules/react-native/third-party-podspecs/Folly.podspec'
target 'TempTests' do
inherit! :search_paths
# Pods for testing
end
use_native_modules!
end
target 'Temp-tvOS' do
# Pods for Temp-tvOS
target 'Temp-tvOSTests' do
inherit! :search_paths
# Pods for testing
end
end
那么,如果我想在更新react native的版本后创建pod文件,那么我们如何像默认的那样创建pod文件呢