create-react-app创建react项目失败!
2017-09-11 17:00
751 查看
create-react-app my-app
用管理员运行cmd,问题依然。
打开日志,看到错误详细信息如下
32189 verbose unlock done using C:\Users\feng\AppData\Roaming\npm-cache\_locks\staging-6ca308cbe79bff06.lock for D:\react\my-app\node_modules\.staging
32190 verbose stack Error: EPERM: operation not permitted, unlink 'D:\react\my-app\node_modules\nan\package.json'
32191 verbose cwd D:\react\my-app
32192 verbose Windows_NT 10.0.14393
32193 verbose argv "D:\\Program Files\\nodejs\\node.exe" "C:\\Users\\feng\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js" "install" "--save" "--save-exact" "--loglevel" "error" "react" "react-dom" "react-scripts"
32194 verbose node v8.2.1
32195 verbose npm v5.4.1
32196 error path D:\react\my-app\node_modules\nan\package.json
32197 error code EPERM
32198 error errno -4048
32199 error syscall unlink
32200 error Error: EPERM: operation not permitted, unlink 'D:\react\my-app\node_modules\nan\package.json'
32200 error { Error: EPERM: operation not permitted, unlink 'D:\react\my-app\node_modules\nan\package.json'
32200 error stack: 'Error: EPERM: operation not permitted, unlink \'D:\\react\\my-app\\node_modules\\nan\\package.json\'',
32200 error errno: -4048,
32200 error code: 'EPERM',
32200 error syscall: 'unlink',
32200 error path: 'D:\\react\\my-app\\node_modules\\nan\\package.json' }
32201 error Please try running this command again as root/Administrator.
32202 verbose exit [ -4048, true ]
网上找到一个答案 https://stackoverflow.com/questions/46103232/creat-react-app-is-not-installing-in-windows-10
让关闭 Windows Defender,我关闭了再试,还是不行。
又找到一个答案 http://blog.csdn.net/greatbody/article/details/61616555
让单独执行命令:
然后再创建项目,可是第三个命令我执行失败!
how?
用管理员运行cmd,问题依然。
打开日志,看到错误详细信息如下
32189 verbose unlock done using C:\Users\feng\AppData\Roaming\npm-cache\_locks\staging-6ca308cbe79bff06.lock for D:\react\my-app\node_modules\.staging
32190 verbose stack Error: EPERM: operation not permitted, unlink 'D:\react\my-app\node_modules\nan\package.json'
32191 verbose cwd D:\react\my-app
32192 verbose Windows_NT 10.0.14393
32193 verbose argv "D:\\Program Files\\nodejs\\node.exe" "C:\\Users\\feng\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js" "install" "--save" "--save-exact" "--loglevel" "error" "react" "react-dom" "react-scripts"
32194 verbose node v8.2.1
32195 verbose npm v5.4.1
32196 error path D:\react\my-app\node_modules\nan\package.json
32197 error code EPERM
32198 error errno -4048
32199 error syscall unlink
32200 error Error: EPERM: operation not permitted, unlink 'D:\react\my-app\node_modules\nan\package.json'
32200 error { Error: EPERM: operation not permitted, unlink 'D:\react\my-app\node_modules\nan\package.json'
32200 error stack: 'Error: EPERM: operation not permitted, unlink \'D:\\react\\my-app\\node_modules\\nan\\package.json\'',
32200 error errno: -4048,
32200 error code: 'EPERM',
32200 error syscall: 'unlink',
32200 error path: 'D:\\react\\my-app\\node_modules\\nan\\package.json' }
32201 error Please try running this command again as root/Administrator.
32202 verbose exit [ -4048, true ]
网上找到一个答案 https://stackoverflow.com/questions/46103232/creat-react-app-is-not-installing-in-windows-10
让关闭 Windows Defender,我关闭了再试,还是不行。
又找到一个答案 http://blog.csdn.net/greatbody/article/details/61616555
让单独执行命令:
npm install -g react npm install -g react-dom npm install -g react-scripts
然后再创建项目,可是第三个命令我执行失败!
how?
相关文章推荐
- create-react-app 创建项目失败
- Create-React-App创建React项目
- 在create-react-app创建的React项目应用中配置JQ、Sass
- 使用create-react-app创建项目
- Create React App快速创建React项目
- 以create-react-app为基础创建项目
- 以create-react-app为基础创建项目
- 使用create-react-app或者antd创建一个React项目
- create-react-app创建项目报错SyntaxError: Unexpected end of JSON input while parsing near '...ttachment":false,"tar' npm代理
- react---学习笔记:使用create-react-app快速构建开发环境并创建项目
- create-react-app如何创建react项目?
- 在create-react-app创建的项目下允许函数绑定运算符
- react以create-react-app为基础创建项目
- create-react-app创建react项目,使用axios跨域
- 使用Create-React-App脚手架创建antd-mobile开发环境 (附 github 源码)
- heroku 自动部署create-react-app项目
- create-react-app项目添加less配置
- creact-react-app创建react项目配置scss
- 利用 Create React Native App 快速创建 React Native 应用
- 用weex create 创建app项目 报 ERROR in index.web.js from UglifyJs 错误!