#react-native
#react-native
Вопрос:
пытаюсь установить «react-native-camera» в мой проект. Я выполняю следующие шаги: https://github.com/react-native-camera/react-native-camera/blob/master/docs/installation.md#requirements
Но при «Дополнительных шагах установки», когда я использую «pod install», он возвращает;
[!] Unable to find a specification for `React-Core` depended upon by `react-native-camera/BarcodeDetectorMLKit`
You have either:
* out-of-date source repos which you can update with `pod repo update` or with `pod install --repo-update`.
* mistyped the name or version.
* not added the source repo that hosts the Podspec to your Podfile.
Мой подфайл ниже:
# Uncomment the next line to define a global platform for your project
platform :ios, '9.0'
target 'blabla' do
# Comment the next line if you don't want to use dynamic frameworks
use_frameworks!
pod 'react-native-camera', path: '../node_modules/react-native-camera', subspecs: [
'BarcodeDetectorMLKit'
]
# Pods for blabla
target 'blablaTests' do
inherit! :search_paths
# Pods for testing
end
end
target 'blabla-tvOS' do
# Comment the next line if you don't want to use dynamic frameworks
use_frameworks!
# Pods for blabla-tvOS
target 'blabla-tvOSTests' do
inherit! :search_paths
# Pods for testing
end
end
Версия React native — 62.0.
Версия React-native-camera — 3.40.0
В чем может быть проблема?
Ответ №1:
добавьте вручную в свой Podfile отсутствующий модуль:
pod 'React-Core', :path => '../node_modules/react-native/React'