A single, version-stamped migration. version is the system version at which the migration is introduced; the runner applies every step whose version is newer than the world's stored migration version and no newer than the running system version. migrators holds one function per in-scope document kind the step needs to touch — omit a kind the step does not change.

interface MigrationStep {
    description: string;
    migrators?: Partial<Record<MigrationDocKind, DocMigrator>>;
    version: string;
}

Properties

description: string

A short human-readable description of what the step changes.

migrators?: Partial<Record<MigrationDocKind, DocMigrator>>

Per-document-kind migrators. Omit a kind the step does not touch.

version: string

The system version this migration was introduced at (e.g. "0.8.0").