Skip to content

fix(intersectionObs): guarding against undefined window #26

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 7, 2019

Conversation

ashbrowning
Copy link
Contributor

Fixes #21

Description
When running a server-side render of my site, I get a 'window is not defined' error thrown from intersection-observer.js. Adding a guard to ensure window is defined before checking for the presence of IntersectionObserver.

Copy link
Owner

@Aljullu Aljullu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you @ashbrowning tested and this is looking good. Will upload a new version today.

@Aljullu Aljullu merged commit 165a619 into Aljullu:master Jan 7, 2019
@ashbrowning ashbrowning deleted the fix/window_undefined_error branch January 7, 2019 14:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants