[英]react-native link giving error no such file or directory info.plist
I am trying to add new font to my react-native project. 我正在尝试将新字体添加到我的react-native项目中。
I have added this in package.json 我已经在package.json中添加了它
"rnpm": {
"assets": [
"./assets/fonts/"
]
}
And added corresponding font file in assets folder as well in project. 并在项目中的资产文件夹中添加了相应的字体文件。
In the process to link the font I need to run - 在链接字体的过程中,我需要运行-
react-native link
But while running the above command I am getting this error - 但是在运行上面的命令时,我得到了这个错误-
Error: ENOENT: no such file or directory, open '/private/var/native-testProject/ios/"tests_tvOSTests/Info.plist"'
at Object.fs.openSync (fs.js:667:18)
at Object.fs.readFileSync (fs.js:572:33)
at Object.<anonymous> (/private/var/www/native-testProject/node_modules/react-native-code-push/scripts/postlink/ios/postlink.js:63:24)
at Module._compile (module.js:662:30)
at Object.Module._extensions..js (module.js:673:10)
at Module.load (module.js:575:32)
at tryModuleLoad (module.js:515:12)
at Function.Module._load (module.js:507:3)
at Module.require (module.js:606:17)
at require (internal/module.js:11:18)
While looking into the project structure I was able to locate the info.plist
file as well. 在查看项目结构时,我也能够找到
info.plist
文件。
I am quite new to react-native and I don't know where I am going wrong. 我对本机反应还很陌生,也不知道我要去哪里。
While looking at the documentation I found that I need to run 在查看文档时,我发现我需要运行
react-native upgrade
My issue was then that some how tests_tvOSTests
was not getting referenced in the project structure, when I ran upgrade every thing was in place. 然后我的问题是,当我运行升级时,在项目结构中没有如何引用
tests_tvOSTests
。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.