title: Knockout paging component crashes. Why?
body: <p>Here is my knockout component that displays a table with some data.
  (I have simplified it as much as I could just to be easier to understand it)</p>
  
  <p>It works fine when there are not much rows in the data array, but if there are 1.5 thousand rows or more it freezes if I flip through all the pages and then crashes with "out of memory" error message.</p>
  
  <p>What may cause the error?
  Is there a way to fix this?</p>
  
  <pre><code>ko.components.register("table-pg", {
      viewModel: function(params) {
          // params
          this.pageSize = +params["pageSize"];
          this.allItems = ko.utils.unwrapObservable( params["values"] );
          this.columns = ko.observableArray( params["columns"] );
  
          this.totalPagesCount = ko.pureComputed(function () {
              return Math.ceil(this.allItems.length / this.pageSize);
          }, this);
  
          this.pageNum = ko.observable(0);
  
          this.items = ko.pureComputed(function () {
              var startIndex = this.pageSize * this.pageNum();
              return this.allItems.slice(startIndex, startIndex + this.pageSize);
          }, this);
  
          this.gotoNextPage = function () {
              var pn = this.pageNum();
              if (pn &lt; this.totalPagesCount() - 1) this.pageNum(pn + 1);
          }
      },
      template:' \
          &lt;div&gt; \
              &lt;table&gt; \
                  &lt;tbody data-bind="foreach: items"&gt; \
                      &lt;tr class="value-item" data-bind="foreach: $component.columns"&gt; \
                          &lt;td data-bind=" \
                              text: ko.pureComputed( function () { \
                                  return $parent.property($data).value()  \
                              } ), \
                          "&gt;&lt;/td&gt; \
                      &lt;/tr&gt; \
                  &lt;/tbody&gt; \
              &lt;/table&gt; \
              \
              &lt;a href="#next" data-bind="click: gotoNextPage, text: nextPageTitle"&gt;&lt;/a&gt; \
          &lt;/div&gt; \
          '
  });
  </code></pre>