@@ -41,7 +41,7 @@ import { cloneArray, mergeObjects, compareMaps, resolveNestedPath, isObject, Pla
4141import { GridColumnDataType } from '../data-operations/data-util' ;
4242import { FilteringLogic , IFilteringExpression } from '../data-operations/filtering-expression.interface' ;
4343import { IGroupByRecord } from '../data-operations/groupby-record.interface' ;
44- import { IgxGridForOfDirective } from '../directives/for-of/for_of.directive' ;
44+ import { IForOfDataChangingEventArgs , IgxGridForOfDirective } from '../directives/for-of/for_of.directive' ;
4545import { IgxTextHighlightDirective } from '../directives/text-highlight/text-highlight.directive' ;
4646import { ISummaryExpression } from './summaries/grid-summary' ;
4747import { RowEditPositionStrategy , IPinningConfig } from './grid.common' ;
@@ -1060,6 +1060,29 @@ export abstract class IgxGridBaseDirective extends DisplayDensityBase implements
10601060 @Output ( )
10611061 public localeChange = new EventEmitter < boolean > ( ) ;
10621062
1063+ /**
1064+ * Emitted before the grid's data view is changed because of a data operation, rebinding, etc.
1065+ *
1066+ * @example
1067+ * ```typescript
1068+ * <igx-grid #grid [data]="localData" [autoGenerate]="true" (dataPreLoad)='handleDataPreloadEvent()'></igx-grid>
1069+ * ```
1070+ */
1071+ @Output ( )
1072+ public dataChanging = new EventEmitter < IForOfDataChangingEventArgs > ( ) ;
1073+
1074+ /**
1075+ * Emitted after the grid's data view is changed because of a data operation, rebinding, etc.
1076+ *
1077+ * @example
1078+ * ```typescript
1079+ * <igx-grid #grid [data]="localData" [autoGenerate]="true" (dataPreLoad)='handleDataPreloadEvent()'></igx-grid>
1080+ * ```
1081+ */
1082+ @Output ( )
1083+ public dataChanged = new EventEmitter < any > ( ) ;
1084+
1085+
10631086 /**
10641087 * @hidden @internal
10651088 */
@@ -3387,6 +3410,20 @@ export abstract class IgxGridBaseDirective extends DisplayDensityBase implements
33873410 }
33883411 }
33893412
3413+ /**
3414+ * @hidden @internal
3415+ */
3416+ public dataRebinding ( event : IForOfDataChangingEventArgs ) {
3417+ this . dataChanging . emit ( event )
3418+ }
3419+
3420+ /**
3421+ * @hidden @internal
3422+ */
3423+ public dataRebound ( event ) {
3424+ this . dataChanged . emit ( event ) ;
3425+ }
3426+
33903427 /** @hidden @internal */
33913428 public createFilterDropdown ( column : ColumnType , options : OverlaySettings ) {
33923429 options . outlet = this . outlet ;
0 commit comments