React section is outdated

Hi guys,
I love freecodecamp, it’s a great resource. I do have one suggestion- and that’s to update the React section. Specifically, the class component approach to using React isn’t how it’s done anymore. In 2018, React creators announced that lifecycle methods are error prone and outdated. You can find this in React Documentation. Instead, React is more about functional components now with the use of the various hooks. i.e. useState, useEffect, the Reducer function, etc. The Redux section is behind the times as well. I’ve seen others post about this. 4 years has gone by, its time to make the changes. Good luck to you! Thank you for everything.

1 Like

You may have noticed that our volunteers are very busy working on many things. The fastest way to get changes is to pitch in yourself!

1 Like

I agree with this. The second I had issues with React projects and tried to Google them, I ended up coming up with code that I didn’t even understand. Functional Components have 9 major hooks that are not even covered. I almost forget they existed until I had started running across them again.

This tutorial allowed me to go from FCC to making projects. Class components can be bulky and confusing with the lifecycle hooks. useContext for example is a massive simplification of passing props, but is never taught in FCC. useImperativeHandle allows for child component references for custom React components, which is important enough to go over (considering that is most of React).

However, when FCC made the React course, its understandable these were not included because they were not prevalent at the time.

This is where I would start. I would make two pre-defined sections of React curriculum: Class and Functional components. Then a third section could go over use cases for both. FCC has been the backbone of my computer science education and I am glad they got me as far as they did. If I had the experience to help out, I would.

1 Like

React section is outdated

Yes, it is.

I do have one suggestion- and that’s to update the React section.

FCC is largely built by volunteers and does not have infinite resources. There are many priorities. If you want to become part of that, you can volunteer your time and eventually become a voice in the direction of FCC. But I don’t think it will be able to keep chasing every change in every library.

In 2018, React creators announced that lifecycle methods are error prone and outdated.

I think that’s a bit of an overstatement. afaik, it’s more that they can lend themselves to questionable patterns than they are inherently flawed.

Instead, React is more about functional components now with the use of the various hooks. i.e. useState, useEffect, the Reducer function, etc.

Yep. I don’t write class components anymore.

But that is not to say that it isn’t REALLY important to learn class components. I have to work on old code all the time where I have to maintain class components. For many of them it would be non-trivial and would take work to rewrite perfectly functional code, possibly inserting bugs into already working systems.

It is also a misconception that sometimes people have the deprecated code (and class components aren’t even deprecated) will suddenly stop working or needs to be updated immediately. There is risk in doing that. And React is still supporting class components and have said that the will support it for some time:

We intend for Hooks to cover all existing use cases for classes, but we will keep supporting class components for the foreseeable future. At Facebook, we have tens of thousands of components written as classes, and we have absolutely no plans to rewrite them. Instead, we are starting to use Hooks in the new code side by side with classes.

This is from the React docs. Note that the bold is from the original.

But I agree that it would be nice to update the React section to teach about an FC based approach and hooks. (I would say that about the JS section too - it has added things since ES6). But FCC has to set its priorities and decide where to allocate limited resources. If you want to volunteer, that would certainly help.

The tl/dr is that you must learn class components, and will need to for some time to come, unless your are working on your own or on a project that only uses FC/hooks and agrees to never uses a library that depends on class components.

That seems very limiting to me. I was always more concerned with learning whatever it took to get me a job.


Creating challenges is a lot of work so is maintaining them. Remember fCC is a nonprofit (donations are welcome). But I agree and I suspect it will happen at some point (not sure what the plan is, to be honest).

As an alternative, you can always check the news section.

And the YouTube channel

1 Like

While it is outdated and having hooks introduced instead could be more useful, class React is still around and any self respecting React dev and any React dev who aims to be hired professionally should know the basic class components syntax and be able to read it. I strongly advise you, do not overlook that section as a source to get familiar with the approach, it definitely will come handy to you, sooner or later. A bit of an advise, you can also look for additional sources to get better familiar with general JS class syntax, which will make it easier for you to grasp class components.
Its also good to know how redux works this way, before you dive for the newer versions, as they can be even harder to comprehend. Some React hooks behavior is also easierto understand, when associated with class components state and lifecicle. With classes, everything is more verbose and manicured in code, while with hooks, things happen with in a shortcut and it can be hard to understand how things work under the hood. Also, to really be able to handle hooks, you also want a very good level of modern js, because they rely on modern syntax


I mean, freeCodeCamp is being currently updated!

You may have noticed these two at the bottom of the list of certifications

All the curriculum is going to be updated with new versions of the certs, + new certs will be added, like the Relational Database one


This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.