diff --git a/API/index.html b/API/index.html index 2c6757fb3..bfe6835b5 100644 --- a/API/index.html +++ b/API/index.html @@ -231,14 +231,14 @@
Ƭ IDisposer: function
-Defined in src/utils.ts:41
+Defined in src/utils.ts:41
A generic disposer.
▸ (): void
Ƭ IHooksGetter: function
-Defined in src/core/node/Hook.ts:19
+Defined in src/core/node/Hook.ts:19
▸ (self
: T): IHooks
Parameters:
@@ -253,11 +253,11 @@Ƭ IMiddlewareEventType: "action" | "flow_spawn" | "flow_resume" | "flow_resume_error" | "flow_return" | "flow_throw"
-Defined in src/core/action.ts:16
+Defined in src/core/action.ts:16
Ƭ IMiddlewareHandler: function
-Defined in src/core/action.ts:54
+Defined in src/core/action.ts:54
▸ (actionCall
: IMiddlewareEvent, next
: function, abort
: function): any
Parameters:
@@ -288,7 +288,7 @@Ƭ ITypeDispatcher: function
-Defined in src/types/utility-types/union.ts:22
+Defined in src/types/utility-types/union.ts:22
▸ (snapshot
: any): IAnyType
Parameters:
@@ -303,22 +303,22 @@Ƭ IValidationContext: IValidationContextEntry[]
-Defined in src/core/type/type-checker.ts:23
+Defined in src/core/type/type-checker.ts:23
Array of validation context entries
Ƭ IValidationResult: IValidationError[]
-Defined in src/core/type/type-checker.ts:36
+Defined in src/core/type/type-checker.ts:36
Type validation result, which is an array of type validation errors
Ƭ Instance: T extends object ? T["Type"] : T
-Defined in src/core/type/type.ts:230
+Defined in src/core/type/type.ts:230
The instance representation of a given type.
Ƭ LivelinessMode: "warn" | "error" | "ignore"
-Defined in src/core/node/livelinessChecking.ts:7
+Defined in src/core/node/livelinessChecking.ts:7
Defines what MST should do when running into reads / writes to objects that have died.
"warn"
: Print a warning (default).Ƭ OnReferenceInvalidated: function
-Defined in src/types/utility-types/reference.ts:43
+Defined in src/types/utility-types/reference.ts:43
▸ (event
: OnReferenceInvalidatedEvent‹STN›): void
Parameters:
@@ -343,26 +343,26 @@Ƭ OnReferenceInvalidatedEvent: object
-Defined in src/types/utility-types/reference.ts:34
+Defined in src/types/utility-types/reference.ts:34
Ƭ ReferenceIdentifier: string | number
-Defined in src/types/utility-types/identifier.ts:144
+Defined in src/types/utility-types/identifier.ts:144
Valid types for identifiers.
Ƭ ReferenceOptions: ReferenceOptionsGetSet‹IT› | ReferenceOptionsOnInvalidated‹IT› | ReferenceOptionsGetSet‹IT› & ReferenceOptionsOnInvalidated‹IT›
-Defined in src/types/utility-types/reference.ts:451
+Defined in src/types/utility-types/reference.ts:451
Ƭ SnapshotIn: T extends object ? T["CreationType"] : T extends IStateTreeNode
Defined in src/core/type/type.ts:235
+Defined in src/core/type/type.ts:235
The input (creation) snapshot representation of a given type.
Ƭ SnapshotOrInstance: SnapshotIn‹T› | Instance‹T›
-Defined in src/core/type/type.ts:276
+Defined in src/core/type/type.ts:276
A type which is equivalent to the union of SnapshotIn and Instance types of a given typeof TYPE or typeof VARIABLE. For primitives it defaults to the primitive itself.
For example:
@@ -388,12 +388,12 @@Ƭ SnapshotOut: T extends object ? T["SnapshotType"] : T extends IStateTreeNode
Defined in src/core/type/type.ts:244
+Defined in src/core/type/type.ts:244
The output snapshot representation of a given type.
Const
DatePrimitive• DatePrimitive: IType‹number | Date, number, Date› = _DatePrimitive
-Defined in src/types/primitives.ts:215
+Defined in src/types/primitives.ts:215
types.Date
- Creates a type that can only contain a javascript Date value.
Example:
const LogLine = types.model({
@@ -409,7 +409,7 @@ src/types/primitives.ts:169
+
Defined in src/types/primitives.ts:169
types.boolean
- Creates a type that can only contain a boolean value.
This type is used for boolean values by default
Example:
@@ -425,7 +425,7 @@ src/types/primitives.ts:150
+
Defined in src/types/primitives.ts:150
types.finite
- Creates a type that can only contain an finite value.
Example:
const Size = types.model({
@@ -440,7 +440,7 @@ src/types/primitives.ts:132
+
Defined in src/types/primitives.ts:132
types.float
- Creates a type that can only contain an float value.
Example:
const Size = types.model({
@@ -451,7 +451,7 @@ Const
identifier
• identifier: ISimpleType‹string› = new IdentifierType()
-Defined in src/types/utility-types/identifier.ts:112
+Defined in src/types/utility-types/identifier.ts:112
types.identifier
- Identifiers are used to make references, lifecycle events and reconciling works.
Inside a state tree, for each type can exist only one instance for each given identifier.
For example there couldn't be 2 instances of user with id 1. If you need more, consider using references.
@@ -467,7 +467,7 @@
Const
identifierNumber
• identifierNumber: ISimpleType‹number› = new IdentifierNumberType()
-Defined in src/types/utility-types/identifier.ts:127
+Defined in src/types/utility-types/identifier.ts:127
types.identifierNumber
- Similar to types.identifier
. This one will serialize from / to a number when applying snapshots
Example:
const Todo = types.model("Todo", {
@@ -483,7 +483,7 @@ src/types/primitives.ts:114
+
Defined in src/types/primitives.ts:114
types.integer
- Creates a type that can only contain an integer value.
Example:
const Size = types.model({
@@ -498,7 +498,7 @@ src/types/primitives.ts:178
+
Defined in src/types/primitives.ts:178
types.null
- The type of the value null
Const
number
@@ -507,7 +507,7 @@ src/types/primitives.ts:96
+
Defined in src/types/primitives.ts:96
types.number
- Creates a type that can only contain a numeric value.
This type is used for numeric values by default
Example:
@@ -523,7 +523,7 @@ src/types/primitives.ts:77
+
Defined in src/types/primitives.ts:77
types.string
- Creates a type that can only contain a string value.
This type is used for string values by default
Example:
@@ -539,12 +539,12 @@ src/types/primitives.ts:187
+
Defined in src/types/primitives.ts:187
types.undefined
- The type of the value undefined
Functions
addDisposer
▸ addDisposer(target
: IAnyStateTreeNode, disposer
: IDisposer): IDisposer
-Defined in src/core/mst-operations.ts:751
+Defined in src/core/mst-operations.ts:751
Use this utility to register a function that should be called whenever the
targeted state tree node is destroyed. This is a useful alternative to managing
cleanup methods yourself using the beforeDestroy
hook.
@@ -579,7 +579,7 @@ addMiddleware
▸ addMiddleware(target
: IAnyStateTreeNode, handler
: IMiddlewareHandler, includeHooks
: boolean): IDisposer
-Defined in src/core/action.ts:161
+Defined in src/core/action.ts:161
Middleware can be used to intercept any action is invoked on the subtree where it is attached.
If a tree is protected (by default), this means that any mutation of the tree will pass through your middleware.
For more details, see the middleware docs
@@ -599,7 +599,7 @@ applyAction
▸ applyAction(target
: IAnyStateTreeNode, actions
: ISerializedActionCall | ISerializedActionCall[]): void
-Defined in src/middlewares/on-action.ts:88
+Defined in src/middlewares/on-action.ts:88
Applies an action or a series of actions in a single MobX transaction.
Does not return any value
Takes an action description as produced by the onAction
middleware.
@@ -617,7 +617,7 @@ applyPatch
▸ applyPatch(target
: IAnyStateTreeNode, patch
: IJsonPatch | ReadonlyArray‹IJsonPatch›): void
-Defined in src/core/mst-operations.ts:124
+Defined in src/core/mst-operations.ts:124
Applies a JSON-patch to the given model instance or bails out if the patch couldn't be applied
See patches for more details.
Can apply a single past, or an array of patches.
@@ -635,7 +635,7 @@ applySnapshot
▸ applySnapshot<C>(target
: IStateTreeNode‹IType‹C, any, any››, snapshot
: C): void
-Defined in src/core/mst-operations.ts:321
+Defined in src/core/mst-operations.ts:321
Applies a snapshot to a given model instances. Patch and snapshot listeners will be invoked as usual.
Type parameters:
▪ C
@@ -653,7 +653,7 @@ array
▸ array<IT>(subtype
: IT): IArrayType‹IT›
-Defined in src/types/complex-types/array.ts:344
+Defined in src/types/complex-types/array.ts:344
types.array
- Creates an index based collection type who's children are all of a uniform declared type.
This type will always produce observable arrays
Example:
@@ -685,7 +685,7 @@
cast
▸ cast<O>(snapshotOrInstance
: O): O
-Defined in src/core/mst-operations.ts:908
+Defined in src/core/mst-operations.ts:908
Casts a node snapshot or instance type to an instance type so it can be assigned to a type instance.
Note that this is just a cast for the type system, this is, it won't actually convert a snapshot to an instance,
but just fool typescript into thinking so.
@@ -722,7 +722,7 @@
Returns: O
The same object cast as an instance
▸ cast<O>(snapshotOrInstance
: TypeOfValue["CreationType"] | TypeOfValue["SnapshotType"] | TypeOfValue["Type"]): O
-Defined in src/core/mst-operations.ts:911
+Defined in src/core/mst-operations.ts:911
Casts a node snapshot or instance type to an instance type so it can be assigned to a type instance.
Note that this is just a cast for the type system, this is, it won't actually convert a snapshot to an instance,
but just fool typescript into thinking so.
@@ -761,7 +761,7 @@
castFlowReturn
▸ castFlowReturn<T>(val
: T): T
-Defined in src/core/flow.ts:34
+Defined in src/core/flow.ts:34
deprecated
Not needed since TS3.6.
Used for TypeScript to make flows that return a promise return the actual promise result.
Type parameters:
@@ -779,7 +779,7 @@ castToReferenceSnapshot
▸ castToReferenceSnapshot<I>(instance
: I): Extract<I, IAnyStateTreeNode> extends never ? I : ReferenceIdentifier
-Defined in src/core/mst-operations.ts:1011
+Defined in src/core/mst-operations.ts:1011
Casts a node instance type to a reference snapshot type so it can be assigned to a reference snapshot (e.g. to be used inside a create call).
Note that this is just a cast for the type system, this is, it won't actually convert an instance to a reference snapshot,
but just fool typescript into thinking so.
@@ -817,7 +817,7 @@
castToSnapshot
▸ castToSnapshot<I>(snapshotOrInstance
: I): Extract<I, IAnyStateTreeNode> extends never ? I : TypeOfValue["CreationType"]
-Defined in src/core/mst-operations.ts:977
+Defined in src/core/mst-operations.ts:977
Casts a node instance type to a snapshot type so it can be assigned to a type snapshot (e.g. to be used inside a create call).
Note that this is just a cast for the type system, this is, it won't actually convert an instance to a snapshot,
but just fool typescript into thinking so.
@@ -854,7 +854,7 @@ clone
▸ clone<T>(source
: T, keepEnvironment
: boolean | any): T
-Defined in src/core/mst-operations.ts:666
+Defined in src/core/mst-operations.ts:666
Returns a deep copy of the given state tree node as new tree.
Shorthand for snapshot(x) = getType(x).create(getSnapshot(x))
Tip: clone will create a literal copy, including the same identifiers. To modify identifiers etc. during cloning, don't use clone but take a snapshot of the tree, modify it, and create new instance
@@ -874,7 +874,7 @@
compose
▸ compose<PA, OA, FCA, FSA, PB, OB, FCB, FSB>(name
: string, A
: IModelType‹PA, OA, FCA, FSA›, B
: IModelType‹PB, OB, FCB, FSB›): IModelType‹PA & PB, OA & OB, _CustomJoin‹FCA, FCB›, _CustomJoin‹FSA, FSB››
-Defined in src/types/complex-types/model.ts:769
+Defined in src/types/complex-types/model.ts:769
types.compose
- Composes a new model from one or more existing model types.
This method can be invoked in two forms:
Given 2 or more model types, the types are composed into a new Type.
@@ -902,7 +902,7 @@
Returns: IModelType‹PA & PB, OA & OB, _CustomJoin‹FCA, FCB›, _CustomJoin‹FSA, FSB››
▸ compose<PA, OA, FCA, FSA, PB, OB, FCB, FSB>(A
: IModelType‹PA, OA, FCA, FSA›, B
: IModelType‹PB, OB, FCB, FSB›): IModelType‹PA & PB, OA & OB, _CustomJoin‹FCA, FCB›, _CustomJoin‹FSA, FSB››
-Defined in src/types/complex-types/model.ts:771
+Defined in src/types/complex-types/model.ts:771
types.compose
- Composes a new model from one or more existing model types.
This method can be invoked in two forms:
Given 2 or more model types, the types are composed into a new Type.
@@ -929,7 +929,7 @@
Returns: IModelType‹PA & PB, OA & OB, _CustomJoin‹FCA, FCB›, _CustomJoin‹FSA, FSB››
▸ compose<PA, OA, FCA, FSA, PB, OB, FCB, FSB, PC, OC, FCC, FSC>(name
: string, A
: IModelType‹PA, OA, FCA, FSA›, B
: IModelType‹PB, OB, FCB, FSB›, C
: IModelType‹PC, OC, FCC, FSC›): IModelType‹PA & PB & PC, OA & OB & OC, _CustomJoin‹FCA, _CustomJoin‹FCB, FCC››, _CustomJoin‹FSA, _CustomJoin‹FSB, FSC›››
-Defined in src/types/complex-types/model.ts:773
+Defined in src/types/complex-types/model.ts:773
types.compose
- Composes a new model from one or more existing model types.
This method can be invoked in two forms:
Given 2 or more model types, the types are composed into a new Type.
@@ -962,7 +962,7 @@
Returns: IModelType‹PA & PB & PC, OA & OB & OC, _CustomJoin‹FCA, _CustomJoin‹FCB, FCC››, _CustomJoin‹FSA, _CustomJoin‹FSB, FSC›››
▸ compose<PA, OA, FCA, FSA, PB, OB, FCB, FSB, PC, OC, FCC, FSC>(A
: IModelType‹PA, OA, FCA, FSA›, B
: IModelType‹PB, OB, FCB, FSB›, C
: IModelType‹PC, OC, FCC, FSC›): IModelType‹PA & PB & PC, OA & OB & OC, _CustomJoin‹FCA, _CustomJoin‹FCB, FCC››, _CustomJoin‹FSA, _CustomJoin‹FSB, FSC›››
-Defined in src/types/complex-types/model.ts:775
+Defined in src/types/complex-types/model.ts:775
types.compose
- Composes a new model from one or more existing model types.
This method can be invoked in two forms:
Given 2 or more model types, the types are composed into a new Type.
@@ -994,7 +994,7 @@
Returns: IModelType‹PA & PB & PC, OA & OB & OC, _CustomJoin‹FCA, _CustomJoin‹FCB, FCC››, _CustomJoin‹FSA, _CustomJoin‹FSB, FSC›››
▸ compose<PA, OA, FCA, FSA, PB, OB, FCB, FSB, PC, OC, FCC, FSC, PD, OD, FCD, FSD>(name
: string, A
: IModelType‹PA, OA, FCA, FSA›, B
: IModelType‹PB, OB, FCB, FSB›, C
: IModelType‹PC, OC, FCC, FSC›, D
: IModelType‹PD, OD, FCD, FSD›): IModelType‹PA & PB & PC & PD, OA & OB & OC & OD, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, FCD›››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, FSD››››
-Defined in src/types/complex-types/model.ts:777
+Defined in src/types/complex-types/model.ts:777
types.compose
- Composes a new model from one or more existing model types.
This method can be invoked in two forms:
Given 2 or more model types, the types are composed into a new Type.
@@ -1032,7 +1032,7 @@
Returns: IModelType‹PA & PB & PC & PD, OA & OB & OC & OD, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, FCD›››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, FSD››››
▸ compose<PA, OA, FCA, FSA, PB, OB, FCB, FSB, PC, OC, FCC, FSC, PD, OD, FCD, FSD>(A
: IModelType‹PA, OA, FCA, FSA›, B
: IModelType‹PB, OB, FCB, FSB›, C
: IModelType‹PC, OC, FCC, FSC›, D
: IModelType‹PD, OD, FCD, FSD›): IModelType‹PA & PB & PC & PD, OA & OB & OC & OD, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, FCD›››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, FSD››››
-Defined in src/types/complex-types/model.ts:779
+Defined in src/types/complex-types/model.ts:779
types.compose
- Composes a new model from one or more existing model types.
This method can be invoked in two forms:
Given 2 or more model types, the types are composed into a new Type.
@@ -1069,7 +1069,7 @@
Returns: IModelType‹PA & PB & PC & PD, OA & OB & OC & OD, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, FCD›››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, FSD››››
▸ compose<PA, OA, FCA, FSA, PB, OB, FCB, FSB, PC, OC, FCC, FSC, PD, OD, FCD, FSD, PE, OE, FCE, FSE>(name
: string, A
: IModelType‹PA, OA, FCA, FSA›, B
: IModelType‹PB, OB, FCB, FSB›, C
: IModelType‹PC, OC, FCC, FSC›, D
: IModelType‹PD, OD, FCD, FSD›, E
: IModelType‹PE, OE, FCE, FSE›): IModelType‹PA & PB & PC & PD & PE, OA & OB & OC & OD & OE, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, _CustomJoin‹FCD, FCE››››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, _CustomJoin‹FSD, FSE›››››
-Defined in src/types/complex-types/model.ts:781
+Defined in src/types/complex-types/model.ts:781
types.compose
- Composes a new model from one or more existing model types.
This method can be invoked in two forms:
Given 2 or more model types, the types are composed into a new Type.
@@ -1112,7 +1112,7 @@
Returns: IModelType‹PA & PB & PC & PD & PE, OA & OB & OC & OD & OE, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, _CustomJoin‹FCD, FCE››››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, _CustomJoin‹FSD, FSE›››››
▸ compose<PA, OA, FCA, FSA, PB, OB, FCB, FSB, PC, OC, FCC, FSC, PD, OD, FCD, FSD, PE, OE, FCE, FSE>(A
: IModelType‹PA, OA, FCA, FSA›, B
: IModelType‹PB, OB, FCB, FSB›, C
: IModelType‹PC, OC, FCC, FSC›, D
: IModelType‹PD, OD, FCD, FSD›, E
: IModelType‹PE, OE, FCE, FSE›): IModelType‹PA & PB & PC & PD & PE, OA & OB & OC & OD & OE, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, _CustomJoin‹FCD, FCE››››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, _CustomJoin‹FSD, FSE›››››
-Defined in src/types/complex-types/model.ts:783
+Defined in src/types/complex-types/model.ts:783
types.compose
- Composes a new model from one or more existing model types.
This method can be invoked in two forms:
Given 2 or more model types, the types are composed into a new Type.
@@ -1154,7 +1154,7 @@
Returns: IModelType‹PA & PB & PC & PD & PE, OA & OB & OC & OD & OE, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, _CustomJoin‹FCD, FCE››››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, _CustomJoin‹FSD, FSE›››››
▸ compose<PA, OA, FCA, FSA, PB, OB, FCB, FSB, PC, OC, FCC, FSC, PD, OD, FCD, FSD, PE, OE, FCE, FSE, PF, OF, FCF, FSF>(name
: string, A
: IModelType‹PA, OA, FCA, FSA›, B
: IModelType‹PB, OB, FCB, FSB›, C
: IModelType‹PC, OC, FCC, FSC›, D
: IModelType‹PD, OD, FCD, FSD›, E
: IModelType‹PE, OE, FCE, FSE›, F
: IModelType‹PF, OF, FCF, FSF›): IModelType‹PA & PB & PC & PD & PE & PF, OA & OB & OC & OD & OE & OF, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, _CustomJoin‹FCD, _CustomJoin‹FCE, FCF›››››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, _CustomJoin‹FSD, _CustomJoin‹FSE, FSF››››››
-Defined in src/types/complex-types/model.ts:787
+Defined in src/types/complex-types/model.ts:787
types.compose
- Composes a new model from one or more existing model types.
This method can be invoked in two forms:
Given 2 or more model types, the types are composed into a new Type.
@@ -1202,7 +1202,7 @@
Returns: IModelType‹PA & PB & PC & PD & PE & PF, OA & OB & OC & OD & OE & OF, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, _CustomJoin‹FCD, _CustomJoin‹FCE, FCF›››››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, _CustomJoin‹FSD, _CustomJoin‹FSE, FSF››››››
▸ compose<PA, OA, FCA, FSA, PB, OB, FCB, FSB, PC, OC, FCC, FSC, PD, OD, FCD, FSD, PE, OE, FCE, FSE, PF, OF, FCF, FSF>(A
: IModelType‹PA, OA, FCA, FSA›, B
: IModelType‹PB, OB, FCB, FSB›, C
: IModelType‹PC, OC, FCC, FSC›, D
: IModelType‹PD, OD, FCD, FSD›, E
: IModelType‹PE, OE, FCE, FSE›, F
: IModelType‹PF, OF, FCF, FSF›): IModelType‹PA & PB & PC & PD & PE & PF, OA & OB & OC & OD & OE & OF, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, _CustomJoin‹FCD, _CustomJoin‹FCE, FCF›››››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, _CustomJoin‹FSD, _CustomJoin‹FSE, FSF››››››
-Defined in src/types/complex-types/model.ts:790
+Defined in src/types/complex-types/model.ts:790
types.compose
- Composes a new model from one or more existing model types.
This method can be invoked in two forms:
Given 2 or more model types, the types are composed into a new Type.
@@ -1249,7 +1249,7 @@
Returns: IModelType‹PA & PB & PC & PD & PE & PF, OA & OB & OC & OD & OE & OF, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, _CustomJoin‹FCD, _CustomJoin‹FCE, FCF›››››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, _CustomJoin‹FSD, _CustomJoin‹FSE, FSF››››››
▸ compose<PA, OA, FCA, FSA, PB, OB, FCB, FSB, PC, OC, FCC, FSC, PD, OD, FCD, FSD, PE, OE, FCE, FSE, PF, OF, FCF, FSF, PG, OG, FCG, FSG>(name
: string, A
: IModelType‹PA, OA, FCA, FSA›, B
: IModelType‹PB, OB, FCB, FSB›, C
: IModelType‹PC, OC, FCC, FSC›, D
: IModelType‹PD, OD, FCD, FSD›, E
: IModelType‹PE, OE, FCE, FSE›, F
: IModelType‹PF, OF, FCF, FSF›, G
: IModelType‹PG, OG, FCG, FSG›): IModelType‹PA & PB & PC & PD & PE & PF & PG, OA & OB & OC & OD & OE & OF & OG, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, _CustomJoin‹FCD, _CustomJoin‹FCE, _CustomJoin‹FCF, FCG››››››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, _CustomJoin‹FSD, _CustomJoin‹FSE, _CustomJoin‹FSF, FSG›››››››
-Defined in src/types/complex-types/model.ts:793
+Defined in src/types/complex-types/model.ts:793
types.compose
- Composes a new model from one or more existing model types.
This method can be invoked in two forms:
Given 2 or more model types, the types are composed into a new Type.
@@ -1302,7 +1302,7 @@
Returns: IModelType‹PA & PB & PC & PD & PE & PF & PG, OA & OB & OC & OD & OE & OF & OG, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, _CustomJoin‹FCD, _CustomJoin‹FCE, _CustomJoin‹FCF, FCG››››››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, _CustomJoin‹FSD, _CustomJoin‹FSE, _CustomJoin‹FSF, FSG›››››››
▸ compose<PA, OA, FCA, FSA, PB, OB, FCB, FSB, PC, OC, FCC, FSC, PD, OD, FCD, FSD, PE, OE, FCE, FSE, PF, OF, FCF, FSF, PG, OG, FCG, FSG>(A
: IModelType‹PA, OA, FCA, FSA›, B
: IModelType‹PB, OB, FCB, FSB›, C
: IModelType‹PC, OC, FCC, FSC›, D
: IModelType‹PD, OD, FCD, FSD›, E
: IModelType‹PE, OE, FCE, FSE›, F
: IModelType‹PF, OF, FCF, FSF›, G
: IModelType‹PG, OG, FCG, FSG›): IModelType‹PA & PB & PC & PD & PE & PF & PG, OA & OB & OC & OD & OE & OF & OG, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, _CustomJoin‹FCD, _CustomJoin‹FCE, _CustomJoin‹FCF, FCG››››››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, _CustomJoin‹FSD, _CustomJoin‹FSE, _CustomJoin‹FSF, FSG›››››››
-Defined in src/types/complex-types/model.ts:796
+Defined in src/types/complex-types/model.ts:796
types.compose
- Composes a new model from one or more existing model types.
This method can be invoked in two forms:
Given 2 or more model types, the types are composed into a new Type.
@@ -1354,7 +1354,7 @@
Returns: IModelType‹PA & PB & PC & PD & PE & PF & PG, OA & OB & OC & OD & OE & OF & OG, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, _CustomJoin‹FCD, _CustomJoin‹FCE, _CustomJoin‹FCF, FCG››››››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, _CustomJoin‹FSD, _CustomJoin‹FSE, _CustomJoin‹FSF, FSG›››››››
▸ compose<PA, OA, FCA, FSA, PB, OB, FCB, FSB, PC, OC, FCC, FSC, PD, OD, FCD, FSD, PE, OE, FCE, FSE, PF, OF, FCF, FSF, PG, OG, FCG, FSG, PH, OH, FCH, FSH>(name
: string, A
: IModelType‹PA, OA, FCA, FSA›, B
: IModelType‹PB, OB, FCB, FSB›, C
: IModelType‹PC, OC, FCC, FSC›, D
: IModelType‹PD, OD, FCD, FSD›, E
: IModelType‹PE, OE, FCE, FSE›, F
: IModelType‹PF, OF, FCF, FSF›, G
: IModelType‹PG, OG, FCG, FSG›, H
: IModelType‹PH, OH, FCH, FSH›): IModelType‹PA & PB & PC & PD & PE & PF & PG & PH, OA & OB & OC & OD & OE & OF & OG & OH, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, _CustomJoin‹FCD, _CustomJoin‹FCE, _CustomJoin‹FCF, _CustomJoin‹FCG, FCH›››››››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, _CustomJoin‹FSD, _CustomJoin‹FSE, _CustomJoin‹FSF, _CustomJoin‹FSG, FSH››››››››
-Defined in src/types/complex-types/model.ts:799
+Defined in src/types/complex-types/model.ts:799
types.compose
- Composes a new model from one or more existing model types.
This method can be invoked in two forms:
Given 2 or more model types, the types are composed into a new Type.
@@ -1412,7 +1412,7 @@
Returns: IModelType‹PA & PB & PC & PD & PE & PF & PG & PH, OA & OB & OC & OD & OE & OF & OG & OH, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, _CustomJoin‹FCD, _CustomJoin‹FCE, _CustomJoin‹FCF, _CustomJoin‹FCG, FCH›››››››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, _CustomJoin‹FSD, _CustomJoin‹FSE, _CustomJoin‹FSF, _CustomJoin‹FSG, FSH››››››››
▸ compose<PA, OA, FCA, FSA, PB, OB, FCB, FSB, PC, OC, FCC, FSC, PD, OD, FCD, FSD, PE, OE, FCE, FSE, PF, OF, FCF, FSF, PG, OG, FCG, FSG, PH, OH, FCH, FSH>(A
: IModelType‹PA, OA, FCA, FSA›, B
: IModelType‹PB, OB, FCB, FSB›, C
: IModelType‹PC, OC, FCC, FSC›, D
: IModelType‹PD, OD, FCD, FSD›, E
: IModelType‹PE, OE, FCE, FSE›, F
: IModelType‹PF, OF, FCF, FSF›, G
: IModelType‹PG, OG, FCG, FSG›, H
: IModelType‹PH, OH, FCH, FSH›): IModelType‹PA & PB & PC & PD & PE & PF & PG & PH, OA & OB & OC & OD & OE & OF & OG & OH, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, _CustomJoin‹FCD, _CustomJoin‹FCE, _CustomJoin‹FCF, _CustomJoin‹FCG, FCH›››››››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, _CustomJoin‹FSD, _CustomJoin‹FSE, _CustomJoin‹FSF, _CustomJoin‹FSG, FSH››››››››
-Defined in src/types/complex-types/model.ts:802
+Defined in src/types/complex-types/model.ts:802
types.compose
- Composes a new model from one or more existing model types.
This method can be invoked in two forms:
Given 2 or more model types, the types are composed into a new Type.
@@ -1469,7 +1469,7 @@
Returns: IModelType‹PA & PB & PC & PD & PE & PF & PG & PH, OA & OB & OC & OD & OE & OF & OG & OH, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, _CustomJoin‹FCD, _CustomJoin‹FCE, _CustomJoin‹FCF, _CustomJoin‹FCG, FCH›››››››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, _CustomJoin‹FSD, _CustomJoin‹FSE, _CustomJoin‹FSF, _CustomJoin‹FSG, FSH››››››››
▸ compose<PA, OA, FCA, FSA, PB, OB, FCB, FSB, PC, OC, FCC, FSC, PD, OD, FCD, FSD, PE, OE, FCE, FSE, PF, OF, FCF, FSF, PG, OG, FCG, FSG, PH, OH, FCH, FSH, PI, OI, FCI, FSI>(name
: string, A
: IModelType‹PA, OA, FCA, FSA›, B
: IModelType‹PB, OB, FCB, FSB›, C
: IModelType‹PC, OC, FCC, FSC›, D
: IModelType‹PD, OD, FCD, FSD›, E
: IModelType‹PE, OE, FCE, FSE›, F
: IModelType‹PF, OF, FCF, FSF›, G
: IModelType‹PG, OG, FCG, FSG›, H
: IModelType‹PH, OH, FCH, FSH›, I
: IModelType‹PI, OI, FCI, FSI›): IModelType‹PA & PB & PC & PD & PE & PF & PG & PH & PI, OA & OB & OC & OD & OE & OF & OG & OH & OI, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, _CustomJoin‹FCD, _CustomJoin‹FCE, _CustomJoin‹FCF, _CustomJoin‹FCG, _CustomJoin‹FCH, FCI››››››››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, _CustomJoin‹FSD, _CustomJoin‹FSE, _CustomJoin‹FSF, _CustomJoin‹FSG, _CustomJoin‹FSH, FSI›››››››››
-Defined in src/types/complex-types/model.ts:805
+Defined in src/types/complex-types/model.ts:805
types.compose
- Composes a new model from one or more existing model types.
This method can be invoked in two forms:
Given 2 or more model types, the types are composed into a new Type.
@@ -1532,7 +1532,7 @@
Returns: IModelType‹PA & PB & PC & PD & PE & PF & PG & PH & PI, OA & OB & OC & OD & OE & OF & OG & OH & OI, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, _CustomJoin‹FCD, _CustomJoin‹FCE, _CustomJoin‹FCF, _CustomJoin‹FCG, _CustomJoin‹FCH, FCI››››››››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, _CustomJoin‹FSD, _CustomJoin‹FSE, _CustomJoin‹FSF, _CustomJoin‹FSG, _CustomJoin‹FSH, FSI›››››››››
▸ compose<PA, OA, FCA, FSA, PB, OB, FCB, FSB, PC, OC, FCC, FSC, PD, OD, FCD, FSD, PE, OE, FCE, FSE, PF, OF, FCF, FSF, PG, OG, FCG, FSG, PH, OH, FCH, FSH, PI, OI, FCI, FSI>(A
: IModelType‹PA, OA, FCA, FSA›, B
: IModelType‹PB, OB, FCB, FSB›, C
: IModelType‹PC, OC, FCC, FSC›, D
: IModelType‹PD, OD, FCD, FSD›, E
: IModelType‹PE, OE, FCE, FSE›, F
: IModelType‹PF, OF, FCF, FSF›, G
: IModelType‹PG, OG, FCG, FSG›, H
: IModelType‹PH, OH, FCH, FSH›, I
: IModelType‹PI, OI, FCI, FSI›): IModelType‹PA & PB & PC & PD & PE & PF & PG & PH & PI, OA & OB & OC & OD & OE & OF & OG & OH & OI, _CustomJoin‹FCA, _CustomJoin‹FCB, _CustomJoin‹FCC, _CustomJoin‹FCD, _CustomJoin‹FCE, _CustomJoin‹FCF, _CustomJoin‹FCG, _CustomJoin‹FCH, FCI››››››››, _CustomJoin‹FSA, _CustomJoin‹FSB, _CustomJoin‹FSC, _CustomJoin‹FSD, _CustomJoin‹FSE, _CustomJoin‹FSF, _CustomJoin‹FSG, _CustomJoin‹FSH, FSI›››››››››
-Defined in src/types/complex-types/model.ts:808
+Defined in src/types/complex-types/model.ts:808
types.compose
- Composes a new model from one or more existing model types.
This method can be invoked in two forms:
Given 2 or more model types, the types are composed into a new Type.
@@ -1596,7 +1596,7 @@
createActionTrackingMiddleware
▸ createActionTrackingMiddleware<T>(hooks
: IActionTrackingMiddlewareHooks‹T›): IMiddlewareHandler
-Defined in src/middlewares/create-action-tracking-middleware.ts:28
+Defined in src/middlewares/create-action-tracking-middleware.ts:28
Note: Consider migrating to createActionTrackingMiddleware2
, it is easier to use.
Convenience utility to create action based middleware that supports async processes more easily.
All hooks are called for both synchronous and asynchronous actions. Except that either onSuccess
or onFail
is called
@@ -1618,7 +1618,7 @@
createActionTrackingMiddleware2
▸ createActionTrackingMiddleware2<TEnv>(middlewareHooks
: IActionTrackingMiddleware2Hooks‹TEnv›): IMiddlewareHandler
-Defined in src/middlewares/createActionTrackingMiddleware2.ts:72
+Defined in src/middlewares/createActionTrackingMiddleware2.ts:72
Convenience utility to create action based middleware that supports async processes more easily.
The flow is like this:
@@ -1655,7 +1655,7 @@
custom
▸ custom<S, T>(options
: CustomTypeOptions‹S, T›): IType‹S | T, S, T›
-Defined in src/types/utility-types/custom.ts:74
+Defined in src/types/utility-types/custom.ts:74
types.custom
- Creates a custom type. Custom types can be used for arbitrary immutable values, that have a serializable representation. For example, to create your own Date representation, Decimal type etc.
The signature of the options is:
export interface CustomTypeOptions<S, T> {
@@ -1709,7 +1709,7 @@
decorate
▸ decorate<T>(handler
: IMiddlewareHandler, fn
: T, includeHooks
: boolean): T
-Defined in src/core/action.ts:200
+Defined in src/core/action.ts:200
Binds middleware to a specific action.
Example:
type.actions(self => {
@@ -1742,7 +1742,7 @@
destroy
▸ destroy(target
: IAnyStateTreeNode): void
-Defined in src/core/mst-operations.ts:698
+Defined in src/core/mst-operations.ts:698
Removes a model element from the state tree, and mark it as end-of-life; the element should not be used anymore
Parameters: