- React has a large community that contributes many useful libraries to React ecosystem
The motivation behind creating react
Traditionally, web application UIs are built using templates or HTML directives. These templates dictate the full set of abstractions that you are allowed to use to build your UI.
React approaches building user interfaces differently by breaking them into components. React uses a real, full-featured programming language to render views, which we see as an advantage over templates for a few reasons:
- By unifying your markup with its corresponding view logic, React can actually make views easier to extend and maintain.
📚 Define some vocabulary
An element is a plain object describing what you want to appear on the screen in terms of the DOM nodes or other components. Elements can contain other elements in their props. Creating a React element is cheap. Once an element is created, it is never mutated.
A component can be declared in several different ways. It can be a class with a render() method. Alternatively, in simple cases, it can be defined as a function. In either case, it takes props as an input and returns an element tree as the output.
Props (which stands for properties) are commonly used terms for component object input argument. This is why people say that the props flow one way in React from parents to children.