Skip to main content

LatestMapArguments Interface

Arguments that are passed to the StateFactory.latestMap function.

Input

This type is "input," meaning that code outside of the library defining it should not read from it. Future versions of this type may add optional members or make typing of members more general.

Signature

export interface LatestMapArguments<T, Keys extends string = string> extends LatestMapArgumentsRaw<T, Keys>

Extends: LatestMapArgumentsRaw<T, Keys>

Type Parameters

ParameterConstraintDefaultDescription
T
Keysstringstring

Properties

PropertyModifiersTypeDescription
keyValidatoroptionalKeySchemaValidator<Keys>An optional function that will be called at runtime to validate the presence data key. A runtime validator is strongly recommended when key type is not simply string.
validatorStateSchemaValidator<T>An optional function that will be called at runtime to validate data value under a key. A runtime validator is strongly recommended.

Property Details

keyValidator

An optional function that will be called at runtime to validate the presence data key. A runtime validator is strongly recommended when key type is not simply string.

Signature

keyValidator?: KeySchemaValidator<Keys>;

Type: KeySchemaValidator<Keys>

See Also

KeySchemaValidator.

validator

An optional function that will be called at runtime to validate data value under a key. A runtime validator is strongly recommended.

Signature

validator: StateSchemaValidator<T>;

Type: StateSchemaValidator<T>

See Also

StateSchemaValidator.