MigrationResult
See source codeResult type returned by migration operations.
Migration operations can either succeed and return the transformed value, or fail with a specific reason. This discriminated union type allows for safe handling of both success and error cases when applying migrations.
type MigrationResult<T> =
| {
reason: MigrationFailureReason
type: 'error'
}
| {
type: 'success'
value: T
}
Prev
MigrationIdNext
QueryExpression