TLPropsMigrations
See source codeTable of contents
A sequence of property migrations for a record type.
Contains an ordered array of migrations that should be applied to transform record properties from one version to another. Migrations can include both property-specific migrations and standalone dependency declarations.
interface TLPropsMigrations {}
Example
const myShapeMigrations: TLPropsMigrations = {
sequence: [
{
id: 'com.myapp.shape.custom/1.0.0',
up: (props) => ({ ...props, version: 1 }),
},
{
id: 'com.myapp.shape.custom/2.0.0',
up: (props) => ({ ...props, newFeature: true }),
},
],
}
Properties
sequence
readonly
readonly sequence: Array<StandaloneDependsOn | TLPropsMigration>
Prev
TLPropsMigrationNext
TLScribble