constructor<
Value = unknown,
Input = Value
>(
valueSchema: SerializableSchema<unknown, Value>,
init:| Name | Type | Description |
|---|---|---|
valueSchema* | SerializableSchema<unknown, Value> | |
init* | ReducedValueInitWithSchema<Value, Input> |
Constructs a ReducedValue instance, which combines a value schema and a reducer function (plus optional input schema).
The schema that describes the type of value stored in state (the "running total").
An object specifying the reducer function (required), inputSchema (optional), and jsonSchemaExtra (optional).