title: How to create a own pagination for observable data?
body: <p>I have a observable data that is iterated inside loop:</p>
  <pre><code>&lt;ng-container *ngIf=&quot;features$ | async as data; else nodata&quot;&gt;
     &lt;ng-container *ngFor=&quot;let item of data.layers&quot;&gt;&lt;/ng-container&gt;
      &lt;app-pagination &gt;&lt;/app-pagination&gt;
  &lt;/ng-container&gt;
  </code></pre>
  <p>The <code>features$</code> is filled by static variable:</p>
  <pre><code>features$.next({layers: {4: [], 3:[]}});
  </code></pre>
  <p>So, I change the value like:</p>
  <pre><code>let changes = features$.getValue();
  chnages[4].push(&quot;new&quot;);
  features$.next(changes);
  </code></pre>
  <p>This way rerenders the whole template, including the changes. It is fit for me.
  But problem is I can not store the state of pagination if user used.</p>
  <p>How to do that?</p>