Installing packages. This might take a couple of minutes.
Installing react, react-dom, and react-scripts with cra-template-typescript...

npm ERR! code 1
npm ERR! path /Users/Tutorial/my-react-project/my-react-app/node_modules/canvas
npm ERR! command failed
npm ERR! command sh -c -- node-gyp rebuild
npm ERR! Package pixman-1 was not found in the pkg-config search path.
npm ERR! Perhaps you should add the directory containing `pixman-1.pc'
npm ERR! to the PKG_CONFIG_PATH environment variable
npm ERR! No package 'pixman-1' found
npm ERR! gyp: Call to 'pkg-config pixman-1 --libs' returned exit status 1 while in binding.gyp. while trying to load binding.gyp
npm ERR! gyp ERR! configure error
npm ERR! gyp ERR! stack Error: `gyp` failed with exit code: 1
npm ERR! gyp ERR! stack at ChildProcess.onCpExit (/Users/Tutorial/my-react-project/my-react-app/node_modules/node-gyp/lib/configure.js:259:16)

如果使用create-react-app创建项目的时候报上面的错,可能是确认了一下环境依赖,

可以尝试下面表格里面的方法。

npm ERR! gyp ERR! cwd /Users/Tutorial/my-react-project/my-react-app/node_modules/canvas
npm ERR! gyp ERR! node -v v16.14.2
npm ERR! gyp ERR! node-gyp -v v8.4.1
npm ERR! gyp ERR! not ok

npm ERR! A complete log of this run can be found in:
npm ERR! /Users/.npm/_logs/2022-11-15T02_01_43_860Z-debug-0.log

最新文章

  1. Android ooVoo Apk附件关联分析
  2. HTML5 Canvas一些常用的操作
  3. Struts2(十三)国际化-internationalization
  4. jquery学习记录
  5. 关键字提取算法之TF-IDF扫盲
  6. linux:ifconfig命令
  7. 【Spring五】AOP之使用注解配置
  8. 使用const 提高函数的健壮性
  9. python虚拟环境搭建大全(转)
  10. pythonのdjango Form简单应用。
  11. WebService的两种方式SOAP和REST有什么不同?
  12. 基于阿里云 DNS API 实现的 DDNS 工具
  13. LeetCode-860. Lemonade Change
  14. docker私有仓库搭建和资源限制
  15. DragonBones龙骨骨骼中的自定义事件(另有声音、动画事件)
  16. 温故而知新-mysql的一些语法show,describe,explain,fulltext
  17. .Net Core 跨平台应用使用串口、串口通信 ,可能出现的问题、更简洁的实现方法
  18. nyoj----522 Interval (简单树状数组)
  19. [NOIP2009]靶形数独 深搜+枝杈优化
  20. 目标检测 — NMS

热门文章

  1. 使用伪元素 before 叹号
  2. Java面向对象之创建对象内存分析
  3. mysql主从故障跳过错误
  4. 《黑马旅游网》综合案例六 BaseServlet 抽取
  5. 单个Java文件连接数据库demo
  6. 4、Normal Equation 的向量投影解法与几何和直觉解释
  7. mysql查询数据是否连续增长
  8. JavaScript基础知识整理(引用类型-Function)
  9. shell_Day06
  10. .NET Core基础:白话管道中间件