@mocanvas/store · interface

StoreSchemaOptions

interface StoreSchemaOptions<R extends UnknownRecord, Props>

This one ships without a description. The signature above is read from the package, and the guides cover the area it belongs to.


Properties · 3

readonly createIntegrityChecker?: ((store: Store<R, Props>) => void) | undefined

Reserved for store-level integrity checks; unused by the schema itself.

readonly migrations?: readonly MigrationSequence[] | undefined
readonly onValidationFailure?: ((data: StoreValidationFailure<R>) => R) | undefined

Called when a record fails validation. Return a repaired record to keep going, or throw to abort the operation. When omitted the error is thrown.

mocanvas is built by Symbio. Free for non-commercial, non-profit and development use; commercial use needs an agreement. Not affiliated with or endorsed by tldraw.