[英]Expo QR code not showing for a React Native App
Usually when I run npm start
/ expo start
the expo CLI starts and I am able to scan the QR code using expo on my phone.通常,当我运行
npm start
/ expo start
expo CLI 时,我可以在手机上使用 expo 扫描二维码。 However after I start the app a few times, the QR code no longer begins to show up and I can no longer scan it.然而,在我启动应用程序几次后,二维码不再出现,我也无法扫描它。
Bottom Lower Corner of the Expo Developer Tools which usually shows a QR code
Expo 开发者工具的底部下角通常显示二维码
NPM command prompt running without a QR code
NPM 命令提示符在没有二维码的情况下运行
For me, I also had an error at the top of the console:对我来说,我在控制台顶部也有一个错误:
Linking is disabled because the client scheme cannot be resolved
To resolve, I simply had to run this:要解决,我只需要运行这个:
npx uri-scheme add [your app name]
It added the uri schemes and the app then showed the QR code.它添加了 uri 方案,然后应用程序显示了二维码。
source: this issue来源: 本期
I have faced the same issue when I updated the expo-cli with this command.当我使用此命令更新 expo-cli 时,我遇到了同样的问题。
npm install -g expo-cli
I have followed these steps and worked for me,我已按照这些步骤为我工作,
CTRL+C
CTRL+C
停止 exponode_modules
folder in the projectnode_modules
文件夹npm install
npm install
npm start
npm start
I hope this would help you.我希望这会对你有所帮助。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.