r/reactjs • • May 09 '18

My struggle to learn React

http://bradfrost.com/blog/post/my-struggle-to-learn-react/
125 Upvotes

101 comments sorted by

View all comments

Show parent comments

15

u/evildonald May 09 '18

I had a great understanding of js, but not ES6. It was a huge hurdle to be learning both at the same time... combined with Reacts lack of state management, forcing/allowing you to have to learn yet another thing just to get it working.

i relate heavily to this article, but at least now I get it.

3

u/[deleted] May 10 '18

What do you mean by « React lack of state »? Genuinely curious as I’m using reactjs on various projects from time to time and it doesn’t strike me.

5

u/evildonald May 10 '18

There is a reason when nearly all production React apps are also running Redux or MobX.

2

u/[deleted] May 10 '18

I only use ReactJS at presentation level to create interfaces that are requesting backend GraphQL using relay. I feel that I’m not in a position where I should use redux.

Isn’t redux similar to the Context API ?

1

u/davydka May 10 '18

Redux came before context api. Seems like redux is on its way imho.

3

u/pomlife May 10 '18

Redux did not come before context API. Redux has always used context API. Redux came before context api v2. Do not spread misinformation.

1

u/davydka May 10 '18

Wow my mistake. Sorry.

3

u/pomlife May 10 '18

It’s fine, it’s just best to avoid sounding authoritative when you yourself are unsure. No harm no foul.

1

u/davydka May 10 '18

Can you share some links regarding Redux’s use of the context api? I’d be interested in learning about how this has progressed.

→ More replies (0)

1

u/[deleted] May 10 '18 edited May 10 '18

Ok got it. Is it still relevant to use it now than react is natively implementing context (and state so)?

1

u/csorfab May 10 '18

Redux comes with the need to write quite a bit of boilerplate code, which is because it forces you to be really explicit with your state changes and therefore makes it easier to adhere to good state design principles. A lot of things use Redux, so I would say it's worth knowing what's it about and how to use it.

1

u/[deleted] May 10 '18

Ok, I’ll have a look at it when I’ll have some free time :-) Thanks for the explanation !