What is React?

Academind by Maximilian Schwarzmüller
A free video tutorial from Academind by Maximilian Schwarzmüller
Online Education
4.6 instructor rating • 25 courses • 1,231,294 students

Lecture description

Let's dive into the most important question first: What is React? In this lecture, we'll take a closer look.

Learn more from the full course

React - The Complete Guide (incl Hooks, React Router, Redux)

Dive in and learn React.js from scratch! Learn Reactjs, Hooks, Redux, React Routing, Animations, Next.js and way more!

40:16:38 of on-demand video • Updated November 2020

  • Build powerful, fast, user-friendly and reactive web apps
  • Provide amazing user experiences by leveraging the power of JavaScript with ease
  • Apply for high-paid jobs or work as a freelancer in one the most-demanded sectors you can find in web dev right now
  • Learn React Hooks & Class-based Components
English So let's get started with React; the what, why and how. Let's start with the, "What is React?" question and let me cite a phrase from the official React page: "React is a JavaScript Library for building User Interfaces." Now, this is a nice statement, but what does it mean...? The first important point is the 'JavaScript Library' part. It is a JavaScript library. It is about building JavaScript-driven apps. React apps run in the browser. They don't run on the server, they run in the browser and this gives us a great advantage. Things happen instantly since they happen in the user's browser. We don't have to wait for a server response to get a new page or to render something new. The other important part in this statement is the 'User Interfaces' part. User Interfaces are basically what the user sees and React is all about using components for building these. If you think about it, you can split up any web page into components. Here's an example (this is just any random web page we can think of). We might have this header area, a sidebar and then, on the right, some content. Now, we clearly can split this up into components. We could have a Header component, a Sidebar component and then a headline in the Article Content component. Now, why is thinking like this important or useful? Well, if we split up our web app or website into such components, we can build these building blocks (these components) as contained pieces of code. We don't have to build our entire web page as one bigger picture. We can build all these tiny things on their own. This of course makes working in teams easier. But even if we're working alone, it makes it easy for us to keep our code manageable. If we change the headline later on, we only have to go into that component and update it; we don't have to find that code in our entire web page code. We can also easily reuse components. For example, if we have a list item component and we want to output a list of these list items, then we only have to write the code once and can then easily reuse it and this is important. React components can be thought of as custom HTML elements. In the end, you're just writing custom HTML elements. This is what React is about and it therefore solves the problem of having to build complex user interfaces with what HTML and JavaScript gives you; by writing maintainable, manageable and reusable pieces of that code which you can throw into your web app wherever you need to use it. Let's have a look at some examples.