Interface GridStatePersistenceApi<InitialState>

interface GridStatePersistenceApi<InitialState> {
    exportState: ((params?: GridExportStateParams) => InitialState);
    restoreState: ((stateToRestore: InitialState) => void);
}

Type Parameters

  • InitialState extends GridInitialStateCommunity

Hierarchy (view full)

Properties

exportState: ((params?: GridExportStateParams) => InitialState)

Generates a serializable object containing the exportable parts of the DataGrid state. These values can then be passed to the initialState prop or injected using the restoreState method.

Type declaration

restoreState: ((stateToRestore: InitialState) => void)

Inject the given values into the state of the DataGrid.

Type declaration

    • (stateToRestore): void
    • Parameters

      Returns void