Hello! During SSR, we're getting the following error:
ReferenceError: Server-side code is attempting to access the global variable "window", which is client only. See https://sapper.svelte.dev/docs/#Server-side_rendering
We were able to fix it by adding some checks against the window object for when pageMode=true in the VirtualScroll.svelte file. Is this something we could have added to the project?
if (pageMode && !(typeof window === 'undefined')) {
Hello! During SSR, we're getting the following error:
ReferenceError: Server-side code is attempting to access the global variable "window", which is client only. See https://sapper.svelte.dev/docs/#Server-side_rendering
We were able to fix it by adding some checks against the window object for when
pageMode=true
in theVirtualScroll.svelte
file. Is this something we could have added to the project?if (pageMode && !(typeof window === 'undefined')) {