基于Gatsby starter博客在Netlify上为我的Gatsby应用程序部署失败

基于Gatsby starter博客在Netlify上为我的Gatsby应用程序部署失败,gatsby,netlify,Gatsby,Netlify,我使用盖茨比入门博客作为我的网站。上次尝试部署时,我遇到了以下错误 1:54:59 PM: error 1:54:59 PM: Your plugins must export known APIs from their gatsby-node.js. 1:54:59 PM: The following exports aren't APIs. Perhaps you made a typo or your plugin is outdated? 1:54:59 PM: See https://

我使用盖茨比入门博客作为我的网站。上次尝试部署时,我遇到了以下错误

1:54:59 PM: error
1:54:59 PM: Your plugins must export known APIs from their gatsby-node.js.
1:54:59 PM: The following exports aren't APIs. Perhaps you made a typo or your plugin is outdated?
1:54:59 PM: See https://www.gatsbyjs.org/docs/node-apis/ for the list of Gatsby Node APIs
1:54:59 PM: - The plugin "gatsby-source-filesystem@2.1.4" is exporting a variable named "createSchemaCustomization" which isn't an API.
1:54:59 PM: - The plugin "gatsby-source-filesystem@2.1.4" is exporting a variable named "createSchemaCustomization" which isn't an API.
我清除了缓存并尝试再次部署,但问题没有解决

当我尝试在我的笔记本电脑上构建项目时,一切都很好。我怎样才能解决这个问题


My,以便您可以检查。

盖茨比源文件系统的版本使用的是盖茨比的API版本,该版本要求的版本高于您的依赖项中的版本
createSchemaCustomization
直到Gatsby@^2.12.0及更高版本才引入。应更新盖茨比源文件系统的对等依赖项,以反映这一点,但此时它仅设置为
^2.0.0
,因此它没有向您发出警告

使用以下工具将盖茨比版本更新至最新版本或兼容版本(2.12以上):

纱线添加gatsby@latest
然后确保将
warn.lock
package.json
推送到存储库中,以便Netlify在构建过程中使用正确的版本