NGRX Flashcards

1
Q

Definition

What is NGRX?

A

NGRX is a comprehensive state management solution for Angular applications that adopts the Redux pattern. It provides a clear and consistent model for managing the state, offering profound benefits in scalability and maintainability.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Definition

What is a Store?

A

RxJS-powered global state management for Angular, inspired by Redux.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Definition

NGRX Building Blocks

A

State, Actions, Reducers, Effects, and Selectors

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Definition

What is State?

A

The entire data state of your application. The state is immutable and can only be changed by applying actions via reducers. An example would be:

interface AppState {
  cart: Array<Product>;
}
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Definition

What are Actions?

A

Actions express unique events, dispatched from components and services, and inform reducers how to change the state.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Definition

What is a Reducer?

A

Reducers handle transitions from one state to the next state. They are functions that handle transitions by determining which Actions need to be handled based on the Action’s type.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Definition

What are Effects?

A

Effects isolate side-effects from components. Side-effects are tasks such as reading DB data, calling APIs, etc.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Definition

What is a Selector?

A

Pure functions to obtain slices of the data in the store.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

NGRX Architecture

A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q
A
How well did you know this?
1
Not at all
2
3
4
5
Perfectly