The React UI loop follows these steps:
The React "magic" is in step 4 - React automatically updates the UI based on your changing data in a performant way. That means you can focus on your data and UI layout, and NOT on how you would have to update the DOM to show those changes.
Chris Achard: [0:00] We're going to start with the React UI cycle, which is that you have data, either in your app or you fetch it from a server. You want the data to get displayed on the screen, so you write a React component to do that. The user then interacts with your website, which may cause the data to update. That is going to update the UI automatically.
[0:17] The beauty of React is that happens automatically after you define your components. Once we have a component that is defined by a function, it will be displayed on the screen with ReactDOM. The way we're going to write React will make it so that whenever the data updates, our component will automatically update in the browser.
Member comments are a way for members to communicate, interact, and ask questions about a lesson.
The instructor or someone from the community might respond to your question Here are a few basic guidelines to commenting on egghead.io
Be on-Topic
Comments are for discussing a lesson. If you're having a general issue with the website functionality, please contact us at support@egghead.io.
Avoid meta-discussion
Code Problems?
Should be accompanied by code! Codesandbox or Stackblitz provide a way to share code and discuss it in context
Details and Context
Vague question? Vague answer. Any details and context you can provide will lure more interesting answers!