[v2] gatsbygram build fails #5354
Labels
help wanted
Issue with a clear description that the community can help with.
type: bug
An issue or pull request relating to a bug in Gatsby
Description
v2 gatsbygram doesn't build, failing with a
window is not defined
error. Disabling thegatsby-plugin-manifest
plugin avoids the error forgatsby develop
, but notgatsby build
.Gatsbygram's
gatsby-browser.js
referenceswindow
which triggers the error.This seems to be caused by
import { apiRunner } from "./api-runner-browser"
incache-dir/loader.js
in addition to importing fromgatsby
in the manifest plugin'sgatsby-ssr.js
.Steps to reproduce
In the v2 branch, run
yarn run dev
oryarn run build
on the gatsbygram example.Expected result
The site should build
Actual result
The build fails with the following error:
Environment
npm list gatsby
): nextgatsby --version
): nextFile contents
See https://github.com/gatsbyjs/gatsby/tree/v2/examples/gatsbygram
The text was updated successfully, but these errors were encountered: