diff --git a/projects/ng-table-virtual-scroll/src/lib/fixed-size-table-virtual-scroll-strategy.ts b/projects/ng-table-virtual-scroll/src/lib/fixed-size-table-virtual-scroll-strategy.ts index 0fffd23..8c997b8 100644 --- a/projects/ng-table-virtual-scroll/src/lib/fixed-size-table-virtual-scroll-strategy.ts +++ b/projects/ng-table-virtual-scroll/src/lib/fixed-size-table-virtual-scroll-strategy.ts @@ -31,8 +31,10 @@ export class FixedSizeTableVirtualScrollStrategy implements VirtualScrollStrateg } set dataLength(value: number) { - this._dataLength = value; - this.onDataLengthChanged(); + if (value !== this._dataLength) { + this._dataLength = value; + this.onDataLengthChanged(); + } } private _dataLength = 0;