Skip to content

Server-side rendering is broken - document not defined #2048

@Webkadabra

Description

@Webkadabra

Just updated to 0.13.1, now I have this error:

500 ReferenceError: document is not defined
   at [object Object].componentWillMount (D:\WebServers\custom_home\bfk-new-este\node_modules\material-ui\lib\overlay.js:64:34)
   at [object Object].ReactCompositeComponentMixin.mountComponent (D:\WebServers\custom_home\bfk-new-este\node_modules\react\lib\ReactCompositeComponent.js:210:12)
   at [object Object].wrapper [as mountComponent] (D:\WebServers\custom_home\bfk-new-este\node_modules\react\lib\ReactPerf.js:66:21)
   at Object.ReactReconciler.mountComponent (D:\WebServers\custom_home\bfk-new-este\node_modules\react\lib\ReactReconciler.js:37:35)
   at ReactDOMComponent.ReactMultiChild.Mixin.mountChildren (D:\WebServers\custom_home\bfk-new-este\node_modules\react\lib\ReactMultiChild.js:241:44)
   at ReactDOMComponent.Mixin._createContentMarkup (D:\WebServers\custom_home\bfk-new-este\node_modules\react\lib\ReactDOMComponent.js:588:32)
   at ReactDOMComponent.Mixin.mountComponent (D:\WebServers\custom_home\bfk-new-este\node_modules\react\lib\ReactDOMComponent.js:478:29)
   at Object.ReactReconciler.mountComponent (D:\WebServers\custom_home\bfk-new-este\node_modules\react\lib\ReactReconciler.js:37:35)
   at [object Object].ReactCompositeComponentMixin.mountComponent (D:\WebServers\custom_home\bfk-new-este\node_modules\react\lib\ReactCompositeComponent.js:225:34)
   at [object Object].wrapper [as mountComponent] (D:\WebServers\custom_home\bfk-new-este\node_modules\react\lib\ReactPerf.js:66:21)
   at Object.ReactReconciler.mountComponent (D:\WebServers\custom_home\bfk-new-este\node_modules\react\lib\ReactReconciler.js:37:35)
   at [object Object].ReactCompositeComponentMixin.mountComponent (D:\WebServers\custom_home\bfk-new-este\node_modules\react\lib\ReactCompositeComponent.js:225:34)
   at [object Object].wrapper [as mountComponent] (D:\WebServers\custom_home\bfk-new-este\node_modules\react\lib\ReactPerf.js:66:21)
   at Object.ReactReconciler.mountComponent (D:\WebServers\custom_home\bfk-new-este\node_modules\react\lib\ReactReconciler.js:37:35)
   at ReactDOMComponent.ReactMultiChild.Mixin.mountChildren (D:\WebServers\custom_home\bfk-new-este\node_modules\react\lib\ReactMultiChild.js:241:44)
   at ReactDOMComponent.Mixin._createContentMarkup (D:\WebServers\custom_home\bfk-new-este\node_modules\react\lib\ReactDOMComponent.js:588:32)
From previous event:
   at D:/WebServers/custom_home/bfk-new-este/src/server/frontend/render.js:77:8
   at D:\WebServers\custom_home\bfk-new-este\node_modules\react-router\lib\match.js:58:5
   at D:\WebServers\custom_home\bfk-new-este\node_modules\react-router\lib\useRoutes.js:120:15
   at done (D:\WebServers\custom_home\bfk-new-este\node_modules\react-router\lib\AsyncUtils.js:49:19)
   at D:\WebServers\custom_home\bfk-new-este\node_modules\react-router\lib\AsyncUtils.js:55:7
   at getComponentsForRoute (D:\WebServers\custom_home\bfk-new-este\node_modules\react-router\lib\getComponents.js:9:5)
   at D:\WebServers\custom_home\bfk-new-este\node_modules\react-router\lib\getComponents.js:28:5
   at D:\WebServers\custom_home\bfk-new-este\node_modules\react-router\lib\AsyncUtils.js:54:5
   at Array.forEach (native)
   at Object.mapAsync (D:\WebServers\custom_home\bfk-new-este\node_modules\react-router\lib\AsyncUtils.js:53:9)
   at Object.getComponents [as default] (D:\WebServers\custom_home\bfk-new-este\node_modules\react-router\lib\getComponents.js:27:15)
   at D:\WebServers\custom_home\bfk-new-este\node_modules\react-router\lib\useRoutes.js:114:37
   at Object.runEnterHooks (D:\WebServers\custom_home\bfk-new-este\node_modules\react-router\lib\TransitionUtils.js:44:5)
   at finishMatch (D:\WebServers\custom_home\bfk-new-este\node_modules\react-router\lib\useRoutes.js:107:24)
   at D:\WebServers\custom_home\bfk-new-este\node_modules\react-router\lib\useRoutes.js:91:13
   at done (D:\WebServers\custom_home\bfk-new-este\node_modules\react-router\lib\AsyncUtils.js:13:14)
   at D:\WebServers\custom_home\bfk-new-este\node_modules\react-router\lib\matchRoutes.js:131:9
   at D:\WebServers\custom_home\bfk-new-este\node_modules\react-router\lib\matchRoutes.js:100:13
   at done (D:\WebServers\custom_home\bfk-new-este\node_modules\react-router\lib\AsyncUtils.js:13:14)

Metadata

Metadata

Assignees

No one assigned

    Labels

    docsImprovements or additions to the documentation.duplicateThis issue or pull request already exists.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions