Skip to content

Commit

Permalink
Fixed: window is not defined (ssr) #1291
Browse files Browse the repository at this point in the history
  • Loading branch information
davidjbradshaw committed Jul 11, 2024
1 parent e1d4e64 commit d5b777b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/child/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ const deprecatedResizeMethods = {
}
const eventCancelTimer = 128
const eventHandlersByName = {}
const hasCheckVisibility = 'checkVisibility' in window
const hasCheckVisibility = window && 'checkVisibility' in window
const heightCalcModeDefault = 'auto'
// const isSafari = /^((?!chrome|android).)*safari/i.test(navigator.userAgent)
const nonLoggableTriggerEvents = { reset: 1, resetPage: 1, init: 1 }
Expand Down Expand Up @@ -78,7 +78,7 @@ let resizeFrom = 'child'
let resizeObserver = null
let sameDomain = false
let sizeSelector = ''
let target = window.parent
let target = window?.parent
let targetOriginDefault = '*'
let tolerance = 0
let triggerLocked = false
Expand Down

0 comments on commit d5b777b

Please sign in to comment.