React components
Explore how to build React components by writing functions that return React elements. Understand how props work, including rendering children inside components. This lesson helps you create reusable components for consistent and dynamic web page styling using React and JSX.
We'll cover the following...
We'll cover the following...
To create a ReactComponent we write a function that returns a ReactElement:
var Wrapper = function(props) {
return React.createElement('div', { className: 'wrapper' });
}
We can then use these components like any DOM Node by passing it into a ...