Type Alias: EditRowWriter<TProps, T>
EditRowWriter<
TProps,T> = (request) => readonlyStoreRowWrite<T>[]
Defined in: model/edit-request.ts:145
Answers which rows of the plugin's own store change with this transaction. A removal and an edit
both call it. Core calls it once per transaction, after the removals are final and before the
EditExtender, and never on a drag preview.
Core stages the answer in the same transaction. The edit and the row writes land in one
ChangeSet, and one undo restores both. A throw aborts the whole transaction. The writer reads
rows, and it never writes: a store write inside it throws MutationDuringExtensionHookError.
A write for an Entry this transaction removes is skipped, because that Entry's rows already go.
ctx.edits.writeRowsWithEdit((request) => rowsAbout(request.proposed).map(withTheNewRow));
Type Parameters
TProps
TProps = Record<string, unknown>
T
T extends object = object
Parameters
request
EditRequest<TProps>
Returns
readonly StoreRowWrite<T>[]