title: How to update the WHOLE state in React-redux?
body: <p>I understand how to update some attributes in the state in redux but, is this good practice if I want to update the WHOLE state? I could obviously copy the current state and modify each attribute of that copy but for objects with a lot of attributes this would be quite time consuming.</p>
  <pre><code>const gameReducer = (state:IGame, action: any) =&gt; {
    switch (action.type) {
      case &quot;GAME_STARTED&quot;:
        return action.payload;
      default:
        return initialState;
    }
  };
  export default gameReducer;
  
  </code></pre>