问题
执行npm install --global create-react-app
时候报错,
报错详细信息如下:
npm WARN deprecated tar@2.2.2: This version of tar is no longer supported, and will not receive security updates. Please upgrade asap.
added 67 packages, and audited 68 packages in 6s
4 packages are looking for funding
run `npm fund` for details
2 high severity vulnerabilities
Some issues need review, and may require choosing
a different dependency.
Run `npm audit` for details.
解决
方案一
不使用npm安装,而是使用yarn
yarn global add create-react-app
方案二
依次执行
npx create-react-app create-react-app
cd create-react-app
npm start