title: Require to apply previously saved filter/sort model while loading ag-grid server-side model
body: <p>I'm trying to load data in ag-grid using server side model. I want to apply some filter/sort model so that data will be loaded in ag-grid based on the sort and filter model applied.</p>
  <p>I'm using useEffect to load a state but its not available in the onGreadReady function, hence not getting applied to ag-grid.</p>
  <p>Link for my POC: <a href="https://codesandbox.io/s/cqo9t?file=/src/index.jx" rel="nofollow noreferrer">https://codesandbox.io/s/cqo9t?file=/src/index.jx</a></p>
  <p>Temporary fix:</p>
  <p>I have temporarily solved it by using a readyToLoad state variable which will be marked true in useEffect Fucntion and used in expression tag as condition to load ag-grid.</p>
  <pre><code>useEffect(() =&gt; { console.log(&quot;In Use effect&quot;); setMyState({ filter: &quot;India&quot;, filterType: &quot;text&quot;, type: &quot;equals&quot; }); setReadyToload(true); }, []);
  
  
  ## readyToload used as condition to load grid.
  {readyToload ? &lt;AgGrid&gt;..&lt;/AgGrid&gt; : &quot;&quot;}
  </code></pre>
  <p>----- Any better solution? –</p>