State type
State type
InternalInternal method to set state directly without events. Used during engine initialization.
Get a deep clone of the current state.
Returns a cloned copy to prevent external mutations.
Set state by key-value or by partial object merge.
Emits 'state-set' event after successful update.
Manages instance state for FetchEngine with event emission.
Provides a clean API for getting, setting, and resetting state with automatic event emission on mutations. Validation is pulled from engine options, not passed as a constructor parameter.
Example