简体   繁体   中英

create-react-app unsupported node version

I'm trying to create a new ReactJS app with create-react-app on Ubuntu 18.10. When I run create-react-app myapp I get the following note:

Note: the project was bootstrapped with an old unsupported version of tools. Please update to Node >=6 and npm >=3 to get supported tools in new projects.

But when I check my node version with node -v I get v10.13.0 and checking npm with npm -v shows 6.4.1. create-react-app --version shows 2.1.1. So both my Node version and npm version are greater than the versions specified.

I'm not sure what to do with this since my versions are already above the versions specified. Any suggestions on how to fix this?

检查路径或根文件夹中是否有任何链接 node_modules/ 文件夹,并在运行命令之前尝试将其删除。

I have also faced the same. I have just cut and paste the my-app folder to my home directory and found solution. You can do the same or reinstall it to your home directory.

Instead of installing create-react-app as globally, you can create a new react project with npx create-react-app myapp .

This happened to me when I installed node on ubuntu using snap. When I uninstalled the snap version and used nvm to install instead, I no longer got that error.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM