Skip to content
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

Change globalObject to this to prevent Node crash #32

Merged
merged 3 commits into from
Feb 15, 2020

Conversation

tlorent
Copy link

@tlorent tlorent commented Feb 13, 2020

We currently use scrollbooster (thank you for the package by the way!) in a React SSR project, with NextJS. Unfortunately, because scrollbooster wants to access the window property, Node crashes. The main problem is that the minified version of this package uses window, so we forked the repo and changed the webpack configuration (because invoking Scrollbooster in a useEffect did not work, nor did changing the import to src/index because it uses ES6 module syntax).

If other developers want to use scrollbooster in combination with SSR, this would help them and prevent Node from crashing.

@ilyashubin ilyashubin merged commit 2608332 into ilyashubin:master Feb 15, 2020
@ilyashubin
Copy link
Owner

Hello and thank you very much. Merged

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