我正在尝试在 Windows 上建立一个 Gatsby 入门项目。具体来说,这个入门项目:https://www.gatsbyjs.com/starters/hasura/gatsby-gitbook-starter/
\n节点:v14.10.1\nnpm:6.14.8\nGatsby CLI 版本:2.12.99\nGatsby 版本:2.18.10
\n我打开一个新终端并根据文档运行 Gatsby Starter 脚本:
\n"gatsby new gatsby-gitbook-starter https://github.com/hasura/gatsby-gitbook-starter"\nRun Code Online (Sandbox Code Playgroud)\n成功克隆初始启动程序后,系统指示我 cd 进入该目录并运行“gatsby-develop”。
\n这会引发以下错误:
\nsuccess open and validate gatsby-configs - 0.081s\n\n ERROR \n\n\nSomething went wrong installing the "sharp" module\n\nCannot find module \'../build/Release/sharp.node\'\nRequire stack:\n- C:\\code\\Sutro\\gatsby-gitbook-starter2\\node_modules\\sharp\\lib\\constructor.js\n- C:\\code\\Sutro\\gatsby-gitbook-starter2\\node_modules\\sharp\\lib\\index.js\n- C:\\code\\Sutro\\gatsby-gitbook-starter2\\node_modules\\gatsby-plugin-sharp\\safe-sharp.js\n- C:\\code\\Sutro\\gatsby-gitbook-starter2\\node_modules\\gatsby-plugin-sharp\\index.js\n- C:\\code\\Sutro\\gatsby-gitbook-starter2\\node_modules\\gatsby-plugin-sharp\\gatsby-node.js\n- C:\\code\\Sutro\\gatsby-gitbook-starter2\\node_modules\\gatsby\\dist\\bootstrap\\resolve-module-exports.js\n- C:\\code\\Sutro\\gatsby-gitbook-starter2\\node_modules\\gatsby\\dist\\bootstrap\\load-plugins\\validate.js\n- C:\\code\\Sutro\\gatsby-gitbook-starter2\\node_modules\\gatsby\\dist\\bootstrap\\load-plugins\\load.js\n- C:\\code\\Sutro\\gatsby-gitbook-starter2\\node_modules\\gatsby\\dist\\bootstrap\\load-plugins\\index.js\n- C:\\code\\Sutro\\gatsby-gitbook-starter2\\node_modules\\gatsby\\dist\\bootstrap\\index.js\n- C:\\code\\Sutro\\gatsby-gitbook-starter2\\node_modules\\gatsby\\dist\\commands\\develop.js\n- C:\\Users\\mxgel\\AppData\\Roaming\\npm\\node_modules\\gatsby-cli\\lib\\create-cli.js\n- C:\\Users\\mxgel\\AppData\\Roaming\\npm\\node_modules\\gatsby-cli\\lib\\index.js\n- C:\\Users\\mxgel\\AppData\\Roaming\\npm\\node_modules\\gatsby-cli\\cli.js\n\n- Remove the "node_modules/sharp" directory, run "npm install" and look for errors\n- Consult the …Run Code Online (Sandbox Code Playgroud)