Interface ComponentTraitInit<R, U>
Properties
Optional extends
Optional key
key: string | boolean
Optional observe
observe: boolean
Optional type
type: unknown
Methods
Optional createTrait
- createTrait(): null | R | U
-
Returns null | R | U
Optional didSetTrait
- didSetTrait(newTrait: null | R, oldTrait: null | R, targetTrait: null | Trait): void
-
Parameters
-
newTrait: null | R
-
oldTrait: null | R
-
targetTrait: null | Trait
Returns void
Optional fromAny
- fromAny(value: R | U): null | R
-
Parameters
Returns null | R
Optional insertTrait
- insertTrait(model: Model, trait: R, targetTrait: null | Trait, key: undefined | string): void
-
Parameters
-
-
trait: R
-
targetTrait: null | Trait
-
key: undefined | string
Returns void
Optional onSetTrait
- onSetTrait(newTrait: null | R, oldTrait: null | R, targetTrait: null | Trait): void
-
Parameters
-
newTrait: null | R
-
oldTrait: null | R
-
targetTrait: null | Trait
Returns void
Optional willSetTrait
- willSetTrait(newTrait: null | R, oldTrait: null | R, targetTrait: null | Trait): void
-
Parameters
-
newTrait: null | R
-
oldTrait: null | R
-
targetTrait: null | Trait
Returns void