title: Cannot add property X, object is not extensible after ngrx 9 update
body: <p>I am having an issue like</p>
  
  <blockquote>
    <p>Cannot add property X, object is not extensible</p>
  </blockquote>
  
  <p>after updating my angular project to angular 9 with Ngrx update as well. When I rollback Ngrxversion to 8 it's working fine. But I need to update that as well to v9 with angular 9 updates. This has happened when I add this as datasource.data in the material table with additional attribute. I think that additional attribute alteration is a reason for that. But I create new array from what we got and tried out like below by using slice.</p>
  
  <pre><code> myDataArray.slice(0)
  </code></pre>
  
  <p>It also not working.</p>
  
  <p>I refer change list of Ngrx version 8 to 9 and migration guideline here <a href="https://ngrx.io/guide/migration/v9" rel="noreferrer">https://ngrx.io/guide/migration/v9</a></p>
  
  <p>As I found there is a special change related to immutability with angular 9. They have defined Action, state and serializability related immutability logic there. And I tried out the method that they have suggested to resolve those issues with Ngrx V9 update here <a href="https://ngrx.io/guide/store/configuration/runtime-checks" rel="noreferrer">https://ngrx.io/guide/store/configuration/runtime-checks</a></p>
  
  <p>But those are not worked for me. It's really helpful if anyone has a solution to this issue. Thanks in advance..</p>
  
  <p>error stack trace.. (I used matDataFlatner as well that's where the object mutation happens)</p>
  
  <blockquote>
    <p>app-error-handler.ts:30 TypeError: Cannot add property level, object
    is not extensible
        at MatTreeFlattener.defaultFlattenerTransform [as transformFunction] (tree-table-flattener-builder.ts:57)
        at MatTreeFlattener._flattenNode (flat-data-source.ts:58)
        at flat-data-source.ts:81
        at Array.forEach ()
        at MatTreeFlattener._flattenChildren (flat-data-source.ts:78)
        at MatTreeFlattener._flattenNode (flat-data-source.ts:65)
        at flat-data-source.ts:92
        at Array.forEach ()
        at MatTreeFlattener.flattenNodes (flat-data-source.ts:92)
        at MatTreeFlatDataSource.set (flat-data-source.ts:138)</p>
  </blockquote>