首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >IOS:无效的` `Podfile`‘文件:没有将nil隐式转换为String

IOS:无效的` `Podfile`‘文件:没有将nil隐式转换为String
EN

Stack Overflow用户
提问于 2022-10-29 13:54:55
回答 1查看 1.1K关注 0票数 2

我刚开始学习反应-本土化。在尝试运行npx pod-install时,我得到:

代码语言:javascript
复制
Scanning for pods...
1.11.3
> pod install
Auto-linking React Native modules for target `AudioOnlyRN`: RNCAsyncStorage, RNCClipboard, react-native-background-timer, react-native-daily-js, and react-native-webrtc
[Codegen] Generating ./build/generated/ios/React-Codegen.podspec.json

[!] Invalid `Podfile` file: no implicit conversion of nil into String.

 #  from /.../react-native/ios/Podfile:9
 #  -------------------------------------------
 #
 >    use_react_native!(:path => config["reactNativePath"])
 #
 #  -------------------------------------------
Couldn't install Pods. Updating the Pods project and trying again...
> pod install --repo-update
Auto-linking React Native modules for target `AudioOnlyRN`: RNCAsyncStorage, RNCClipboard, react-native-background-timer, react-native-daily-js, and react-native-webrtc
[Codegen] Generating ./build/generated/ios/React-Codegen.podspec.json

[!] Invalid `Podfile` file: no implicit conversion of nil into String.

 #  from /.../react-native/ios/Podfile:9
 #  -------------------------------------------
 #
 >    use_react_native!(:path => config["reactNativePath"])
 #
 #  -------------------------------------------
Couldn't install Pods. Updating the Pods project and trying again...
Command `pod install` failed.
└─ Cause: Invalid `Podfile` file: no implicit conversion of nil into String.

 #  from /.../react-native/ios/Podfile:9
 #  -------------------------------------------
 #
 >    use_react_native!(:path => config["reactNativePath"])
 #
 #  -------------------------------------------

你知道我在这里发生了什么错配吗?

我不确定我是否理解节点_模块/Package.json和Podfile之间关系的层次结构。

EN

回答 1

Stack Overflow用户

发布于 2022-11-01 06:08:23

试着改变

代码语言:javascript
复制
use_react_native!(:path => config["reactNativePath"])
                                  ^               ^

代码语言:javascript
复制
use_react_native!(:path => config[:reactNativePath])
                                  ^
票数 13
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/74245902

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档