Expo CLI已全局安装,但"npm start"已安装命令仍然询问 [英] Expo CLI is installed globally but "npm start" command still asks
问题描述
我已经全局安装了expo-cli
.但是,当我尝试运行命令npm start
时,它仍然要求全局安装expo-cli
.为什么?
即使机器重新启动后,我仍重新安装了expo-cli
,但存在相同的问题.
以下是屏幕截图,以获取更多详细信息:
实际上,当我重新安装expo-cli
时,这是一个更新版本,并且与项目文件不匹配,因为该项目是使用expo init
初始化的.>
我创建了另一个目录,使用expo init
重新初始化,现在npm stat
命令就像一个超级按钮一样.
I have installed expo-cli
globally. But when I try to run command npm start
it still asks to install expo-cli
globally. Why?
I have reinstalled expo-cli
again but same issue, even after machine restart.
Here is the screenshot for further details:
Actually as I reinstalled expo-cli
which was an updated version and was not matching with the project files, as the project was initialized using expo init
.
I created another directory, reinitialized using expo init
and now npm stat
command works like a charm.
这篇关于Expo CLI已全局安装,但"npm start"已安装命令仍然询问的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!