Headers type
Params type
State type
Headers type
Params type
State type
InternalSet an option directly without emitting events.
Used internally for backward compatibility methods that emit their own specific events.
Get a deep clone of all options or a specific nested value.
Returns a cloned copy to prevent external mutations. All return types are properly inferred from EngineConfig.
Get a deep clone of all options or a specific nested value.
Returns a cloned copy to prevent external mutations. All return types are properly inferred from EngineConfig.
Register a validator that runs against a pending set() before it
mutates the store.
The validator throws to reject the change — nothing mutates and no
config-change event fires. Generic on purpose: the store has no
opinion on what makes a change valid, only that rejection must
happen before mutation. Callers (e.g. the engine's policy-ownership
check) own the actual rule.
Called with the pending change before mutation
Cleanup function to unregister the validator
Set options by path-value or by partial object merge.
Runs registered pre-set validators against the pending change before
anything mutates — a validator that throws rejects the whole set()
call, so a rejected change never partially applies. Emits
'config-change' after a successful update. All values are
type-checked against EngineConfig.
Set options by path-value or by partial object merge.
Runs registered pre-set validators against the pending change before
anything mutates — a validator that throws rejects the whole set()
call, so a rejected change never partially applies. Emits
'config-change' after a successful update. All values are
type-checked against EngineConfig.
Set options by path-value or by partial object merge.
Runs registered pre-set validators against the pending change before
anything mutates — a validator that throws rejects the whole set()
call, so a rejected change never partially applies. Emits
'config-change' after a successful update. All values are
type-checked against EngineConfig.
Manages configuration options for FetchEngine with deep path access.
Provides a clean API for getting and setting nested configuration values with type-safe paths and automatic event emission on mutations. ConfigStore is the single source of truth for ALL configuration.
The store is fully typed with EngineConfig, ensuring:
get('baseUrl')returnsstringget('retry.maxAttempts')returnsnumberget('dedupePolicy')returns the correct policy typeset('timeout', value)validates value is a numberExample