Back to Teable

adapter-undo-redo-keyv Architecture Notes

packages/v2/adapter-undo-redo-keyv/ARCHITECTURE.md

1.10.0688 B
Original Source

Declaration: If the folder I belong to changes, please update me, especially public exports or storage behavior.

adapter-undo-redo-keyv Architecture Notes

Responsibilities

  • Provide a Keyv-backed implementation of @teable/v2-core IUndoRedoStore.
  • Persist undo/redo entries with cursor semantics compatible with UndoRedoService.
  • Keep storage concerns out of v2/core.

Files

  • src/KeyvUndoRedoStore.ts - Role: store adapter; Purpose: persist undo/redo entries in Keyv.
  • src/KeyvUndoRedoStore.spec.ts - Role: unit tests; Purpose: verify cursor, redo truncation, and retention semantics.
  • src/index.ts - Role: package entry; Purpose: export the adapter surface.