Skip to Content
Notion UI
Table View

Edit logs

Display paginated history for a table or a row.

Usage

Pass fetchTableEditLogs to add Edit log to View Settings. Pass fetchRowEditLogs to add it to each row's action menu. The main Table View preview uses static sample history.

<TableView
  defaultData={data}
  defaultProperties={properties}
  fetchTableEditLogs={fetchTableEditLogs}
  fetchRowEditLogs={fetchRowEditLogs}
/>

Your application stores the history. Implement the callbacks to read it from your backend.

Callbacks

Import FetchTableEditLogs and FetchRowEditLogs from @notion-kit/table-view. Each callback receives an optional cursor and an AbortSignal. The row callback also receives rowId. Forward the signal to the request.

Return an EditLogPage<T> containing items and nextCursor. Sort records newest first, keep IDs stable across pages, and return nextCursor: null on the last page. The viewer fetches the first page when opened and fetches more when the user selects Load more. Closing history cancels the request.

Records

import type { RowEditLog, TableEditLog } from "@notion-kit/table-view";

const tableRecord: TableEditLog = {
  id: "log-1",
  editedAt: Date.UTC(2026, 8, 17, 9),
  action: "update-config",
  target: { id: "score", name: "Score" },
  property: { id: "score", name: "Score", type: "number" },
};

const rowRecord: RowEditLog = {
  id: "log-2",
  editedAt: Date.UTC(2026, 8, 17, 10),
  rowId: "row-1",
  property: { id: "notes", name: "Notes", type: "text" },
  value: "Ready for review",
  textValue: "Ready for review",
};

For table records, use TableEditLogAction and include the snapshot for the action.

ActionSnapshot
"update"Set target.name to the historical row title and provide cell: { property, value, textValue }.
"change-layout"Set layout to the destination layout.
"group"Provide groupBy for the selected property. Omit it when clearing grouping.
"change-type"Provide the historical property snapshot.
"rename"Set target.name to the new name.

For row and cell records, capture the property name, type, icon, and relevant configuration at the time of the edit. Include historical option metadata or formatting settings when the renderer needs them. Store resolved timestamps in milliseconds for Created time and Last edited time. The viewer uses textValue when it cannot render the snapshot.

See read-only history renderers to support a custom property type.

On this page