⚠️ Breaking Change
MfeStateService no longer falls back to in-memory defaults when a key is missing from localStorage.
Changed
- Fail-fast initialisation: if a key is missing from localStorage in a browser environment, an error is thrown immediately rather than silently using a default value
- Two-pass init: shell-provided
initialStatevalues are written to localStorage on first boot (if not already present), then signals are initialised exclusively from localStorage - SSR / non-browser environments (no localStorage) still use the provided
initialStatevalue directly - Removed unused internal
defaultsmap fromMfeStateService - Updated docs to reflect fail-fast semantics and shell ownership of initial values
Why
The shell always loads first and owns all initial values. Any key missing from localStorage at init time indicates misconfiguration — surfacing it as an error is safer than returning a stale or wrong default.