Skip to content

Commit e8a7e3b

Browse files
GatsbyJS Botwardpeet
andauthored
fix(gatsby-plugin-preact): fix fast-refresh (#29831) (#29860)
(cherry picked from commit 81a3776) Co-authored-by: Ward Peeters <[email protected]>
1 parent e7453c3 commit e8a7e3b

File tree

1 file changed

+1
-1
lines changed
  • packages/gatsby/cache-dir/fast-refresh-overlay

1 file changed

+1
-1
lines changed

packages/gatsby/cache-dir/fast-refresh-overlay/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ function DevOverlay({ children }) {
5454
const [state, dispatch] = React.useReducer(reducer, initialState)
5555

5656
React.useEffect(() => {
57-
const gatsbyEvents = window._gatsbyEvents
57+
const gatsbyEvents = window._gatsbyEvents || []
5858
window._gatsbyEvents = {
5959
push: ([channel, event]) => {
6060
if (channel === `FAST_REFRESH`) {

0 commit comments

Comments
 (0)