NgRx Store Fundamentals
Explain the core NgRx concepts (store, actions, reducers) and the unidirectional data flow they enforce.
NgRx is Angular's most widely-adopted Redux-pattern state management library, and its core promise is a single, centralized, immutable store of application state, changed only through a strict, predictable, unidirectional data flow — components dispatch actions describing what happened, reducers compute a new state based on that action, and the store notifies subscribers of the updated state, with no component ever mutating shared state directly. Interviewers ask about this because large Angular applications frequently reach for NgRx once state sharing/coordination across many features becomes too complex for scattered services alone, and understanding the core flow is prerequisite to every more advanced NgRx topic.
It's like a court reporter's transcript of a trial — every event (action) is recorded in order, and the official record (state) is only ever updated by appending a new, complete entry based on what was just recorded, never by erasing or editing something that was already written down.