gatsby develop success openly and validate gatsby-configs - 0.005 s
error Something went wrong installing the "sharp" module The module
'\?\D:\korero\node_modules\sharp\build\Release\sharp.node' was
compiled against a different Node.js version using NODE_MODULE_VERSION
64. This version of Node.js requires NODE_MODULE_VERSION 79. Please try re-compiling or re-installing the module (for instance, using npm
rebuild
or npm install
).
- Ensure the version of Node.js used at install time matches that used at runtime
- Consult the installation documentation at https://sharp.pixelplumbing.com/en/stable/install/ https://sharp.pixelplumbing.com/en/stable/install/
- Search for this error at https://github.com/lovell/sharp/issues https://github.com/lovell/sharp/issues ⠋ load plugins
看起来你已经升级了 NodeJS 版本? Sharp 软件包最初是在错误状态下的不同节点版本下安装和构建的。
编译针对NODE_MODULE_VERSION = 64
(NodeJS 10.x) 而您当前的 NodeJS 期望NODE_MODULE_VERSION = 79
这意味着您正在使用 Node 13。
一个简单的修复方法就是简单地运行:
npm rebuild
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)