Book Image

Beginning Frontend Development with React

By : Erik Hanchett, David Parker
Book Image

Beginning Frontend Development with React

By: Erik Hanchett, David Parker

Overview of this book

Through this course, you'll learn the basics you need to get up and running with React and tackle real-world projects and challenges. It begins by explaining the basics of React and shows you the nuances while setting up a React-based application and designing a UI. Once you are comfortable in the React world, you are introduced to components and how to compose them using JSX. With this course, you can learn advanced concepts, such as data propagation, data binding, and also discover how to manage the internal state of a component. You'll also learn about component lifecycle events and understand how to manage routing. By the time you are done with the course, you'll find yourself feeling confident to take on real-world projects. The resource files are uploaded on the GitHub repository at https://github.com/TrainingByPackt/Beginning-Frontend-Development-with-React-eLearning
Table of Contents (3 chapters)
Chapter 3
Managing User Interactivity
Content Locked
Section 5
Component Lifecycle Events
In a React application, components are created dynamically, according to the evolution of the application at runtime. Let us get a brief idea about a component’s lifecycle events and a component’s constructor execution. Let us then look into the event flow and highlights of the grouped lifecycle events of Mounting, Updating via props, and Updating via setState(). After component creation, let us learn that React will trigger a few events corresponding to the respective phases of the component's lifecycle and finally let’s learn how to show the quantity of items added to the cart.