Skip to main content

Interface: AnyDataModel

Any kind of data model instance.

Extends​

Properties​

[propsTypeSymbol]​

[propsTypeSymbol]: any;

Inherited from​

BaseDataModel.[propsTypeSymbol]


$​

readonly $: object;

Data part of the model, which is observable and will be serialized in snapshots. Use it if one of the data properties matches one of the model properties/functions. This also allows access to the backed values of transformed properties.

Index Signature​

[key: string]: any

Inherited from​

BaseDataModel.$

Methods​

toString()​

toString(options?): string;

Parameters​

ParameterType
options?{ withData?: boolean; }
options.withData?boolean

Returns​

string

Inherited from​

BaseDataModel.toString


typeCheck()​

typeCheck(): TypeCheckError | null;

Performs a type check over the model instance. For this to work a data type has to be declared as part of the model properties.

Returns​

TypeCheckError | null

A TypeCheckError or null if there is no error.

Inherited from​

BaseDataModel.typeCheck