UNPKG

devextreme

Version:

HTML5 JavaScript Component Suite for Responsive Web Development

36 lines (35 loc) 1.03 kB
/** * DevExtreme (esm/__internal/grids/new/grid_core/lifecycle/controller.js) * Version: 25.1.3 * Build date: Wed Jun 25 2025 * * Copyright (c) 2012 - 2025 Developer Express Inc. ALL RIGHTS RESERVED * Read about DevExtreme licensing here: https://js.devexpress.com/Licensing/ */ class LifeCycleEvent { constructor() { this.callbacks = new Set } schedule(cb) { this.callbacks.add(cb) } trigger() { for (const cb of this.callbacks) { cb() } this.callbacks.clear() } } export class LifeCycleController { constructor() { this.contentRendered = new LifeCycleEvent } provideContentReadyCallback(cb) { this.contentReadyCallback = cb } fireContentReady() { var _this$contentReadyCal; null === (_this$contentReadyCal = this.contentReadyCallback) || void 0 === _this$contentReadyCal || _this$contentReadyCal.call(this) } } LifeCycleController.dependencies = [];