Slice
@rotorsoft/act-root / act/src / Slice
Type Alias: Slice<TSchemaReg, TEvents, TActions, TStateMap, TActor>
Slice<
TSchemaReg,TEvents,TActions,TStateMap,TActor> =object
Defined in: libs/act/src/slice-builder.ts:37
A self-contained functional slice grouping partial states with their
scoped reactions. Slices are composed into an Act orchestrator via
act().withSlice(slice).
Type Parameters
TSchemaReg
TSchemaReg extends SchemaRegister<TActions>
Schema register for states
TEvents
TEvents extends Schemas
Event schemas from this slice's states
TActions
TActions extends Schemas
Action schemas from this slice's states
TStateMap
TStateMap extends Record<string, Schema> = { }
Map of state names to state schemas
TActor
Actor type extending base Actor
Properties
_tag
readonly_tag:"Slice"
Defined in: libs/act/src/slice-builder.ts:45
events
readonlyevents:EventRegister<TEvents>
Defined in: libs/act/src/slice-builder.ts:47
projections
readonlyprojections:ReadonlyArray<Projection<any>>
Defined in: libs/act/src/slice-builder.ts:48
states
readonlystates:Map<string,State<any,any,any>>
Defined in: libs/act/src/slice-builder.ts:46