[英]react-native run-windows gives error : Certificate could not be opened: TemporaryKey.pfx error
I am working on the react-native-windows project.我正在研究 react-native-windows 项目。 I followed the instructions given here https://microsoft.github.io/react-native-windows/docs/getting-started .我按照这里给出的说明https://microsoft.github.io/react-native-windows/docs/getting-started 。 In the run command, react-native run-windows
, I get an error error : Certificate could not be opened: TemporaryKey.pfx
在运行命令react-native run-windows
,出现错误error : Certificate could not be opened: TemporaryKey.pfx
I am running Microsoft Visual Studio Community 2019 Version 16.7.2 on Windows 10 version 2004 build 19041.450我在 Windows 10 version 2004 build 19041.450 上运行 Microsoft Visual Studio Community 2019 Version 16.7.2
Try opening the YourApp.sln file in the Solution Explorer in Visual Studio (there is a little dropdown to switch views in the solution explorer at the top).尝试在 Visual Studio 的解决方案资源管理器中打开 YourApp.sln 文件(顶部的解决方案资源管理器中有一个小下拉菜单可以切换视图)。 Then open Package.appxmanifest and go to the "Packaging" tab.然后打开 Package.appxmanifest 并转到“Packaging”选项卡。 There should be something that says "Publisher" about halfway down with a button that says "Choose Certificate".中间应该有一个写着“发布者”的东西,上面有一个写着“选择证书”的按钮。 Click that.单击那个。 There are three buttons below that say Select from store, Select from file, and Create.下面有三个按钮,分别是从商店中选择、从文件中选择和创建。 Click create.单击创建。 Enter the info and okay, then build again with npx react-native run-windows in the terminal.输入信息并确定,然后在终端中使用 npx react-native run-windows 再次构建。 It should clear that error about the Certificate.它应该清除有关证书的错误。 I found that I also have to do yarn install first.我发现我还必须先安装纱线。 Hope that helps.希望有帮助。 I'm just learning myself so I may not be right.我只是在学习自己,所以我可能是对的。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.