Echo JS 0.11.0

<~>

kali 713 days ago. link 2 points
Again...

You're trying to explain *CONCEPTS*... But you don't. Instead you focus on using some superficial technical details as if they were the relevant idea.

So you say things like "state is a type of object" that holds the application state. Or "Actions are a simple JavaScript object" that has "a type field that specifies the type of action to take". That is, you're using the term you should be defining inside the definition you're giving. The state is an object that holds the state. An action is an object with a property that indicates the action to take.

That doesn't work. You're not explaining things. You're just throwing words around.

You focus too much on irrelevant details. Reducer functions are expected to be pure... let's spend some paragraphs on this particular detail of pure functions. The spread operator is an easy thing to use when you want to build a new object that is very similar to an existing one without modifying the original one... super cool, let's write a whole section on this as if it was a super important thing specific to Redux reducers.

The conclusion is...

    "Reducers are a crucial component of Redux state management because they allow us to construct pure functions to update specified portions of our Redux apps without causing side effects. We’ve covered the fundamentals of Redux reducers, their applications, and the core concept of reducers, state, and actions."

But this is not what the conclusion should be. Reducers do NOT "allow us to create pure functions", reducers *are* the functions we create and are expected to be pure. And no, you have not explained the core concepts.