title: Redux Toolkit - I can't update Slice state?
body: <p>I wanna update the state and tried few ways to do that, but I can't.
  First, I got a <a href="https://stackoverflow.com/questions/65764486/why-reducer-function-return-only-proxy-redux-toolkit">problem</a> with fetching state, as a result, I got proxy, not a state.</p>
  <p>That is fixed by the <code>current()</code> function by the redux toolkit.
  Next, where I have a problem is mutation main slice state.</p>
  <p>Here is a reducer for mutating.</p>
  <pre><code>reducers: {
      setUser: (state, payload) =&gt; {
        console.log(&quot;before&quot;, current(state)); //init state
        state.currentUser = {
          ...state.currentUser,
          loggined: true,
        };
        console.log(&quot;after&quot;, current(state)); // here I have new state but...
        
      },
      clearUser: (state) =&gt; {},
    },
  </code></pre>
  <p>As a result, as a second console log, I got to state what I want, when I want to change a page or just want to do something with new data in the state, by  <code>useSelector()</code> redux function, as a result, I got old, not changed state.</p>
  <p>Why has this happened?</p>
  <p>Example of Slice state:</p>
  <pre><code>initialState: {
      currentUser: {
        loggined: false,
        isAdmin: false,
        jwt: false,
      },
    },
  </code></pre>
  <p>Thanks!</p>