### setOnSaveCallback · function

Set a callback function to be called after a model is saved and committed.

**Signature:** `(callback: (commitId: number, items: Map<ModelBase<ModelLookup<readonly any[]>>, Change>) => void) => void`

**Parameters:**

- `callback: ((commitId: number, items: Map<Model<unknown>, Change>) => void) | undefined` - The callback function to set. It gets called after each successful
`transact()` commit that has changes, with the following arguments:
- A sequential number. Higher numbers have been committed after lower numbers.
- A map of model instances to their changes. The change can be "created", "deleted", or an object containing the old values.

The callback is called within a new transaction context at or after the committed state, so lazy-loads
and additional writes are allowed.
