concept first render in category isomorphic web applications

appears as: first render
Isomorphic Web Applications: Universal Development with React

This is an excerpt from Manning's book Isomorphic Web Applications: Universal Development with React.

In an isomorphic app, the first render cycle is the most important. That’s where you’ll use lifecycle events to control what environment the code runs in. For example, some third-party libraries aren’t loadable or usable on the server because they rely on the window object. Or you might want to add custom scroll behavior on the window event. You’ll need to control this by hooking into the various lifecycle methods available on the first render.

That’s because your server can’t find a global variable called window. The window object doesn’t exist in Node.js. If you put this code into any of the methods that run during the first render (constructor, componentWillMount, or render), it’ll break on the server.

Conversely, componentDidMount, which runs after the first render is complete, is called only in the browser. This distinction becomes powerful when you need to update a component after reaching the browser but you don’t want to break the isomorphic render.