cmswalker / fullpage-react

Stateful fullpage.js inspired scrolling for React
https://cmswalker.github.io/fullpage-react/
206 stars 42 forks source link

Server side rendering issue #63

Closed buesing closed 6 years ago

buesing commented 6 years ago

Hi, I can't seem to get it to work when using SSR, getting this error:

ReferenceError: document is not defined
    at determineVerticalRoot (/Users/moriz/dev/node_modules/fullpage-react/webpack:/lib/components/Fullpage.js:522:5)
    at new Fullpage (/Users/moriz/dev/node_modules/fullpage-react/webpack:/lib/components/Fullpage.js:65:25)
    ...

(this is using the next.js framework)

cmswalker commented 6 years ago

This has come up in the past. Do you have a repo I can reproduce on? Otherwise I'll try on next.js boilerplate

buesing commented 6 years ago

Not a public one. It should happen in the next.js boilerplate too.

Michael Walker notifications@github.com schrieb am Fr., 12. Jan. 2018 um 17:49 Uhr:

This has come up in the past. Do you have a repo I can reproduce on? Otherwise I'll try on next.js boilerplate

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/cmswalker/fullpage-react/issues/63#issuecomment-357288414, or mute the thread https://github.com/notifications/unsubscribe-auth/ABIGu1Oiglh6lfruROAk1VogURkU2GJrks5tJ4o5gaJpZM4RcdnM .

cmswalker commented 6 years ago

Addressed https://github.com/cmswalker/fullpage-react/pull/64

cmswalker commented 6 years ago

Thanks for finding

npm i fullpage-react@3.0.23

buesing commented 6 years ago

Fixed, thanks