JS 403 — 3 weeks into it

Will McClure
Apr 7, 2021

What is render() in React? Explain its purpose.

It is a class component’s only required method. We use it to tell the method the view that should be presented in the browser to a user.

Is setState() async?

Yes, and its actions are batched to improve performance.

What are controlled components?

It is one that stores its current value through using props. It is often used with a callback to notify of changes. This is in opposition to an Uncontrolled Component that doesn’t use props and use internal tracking for its state.

What is the event loop in JavaScript?

It monitors any Calls that are in the queue, and anytime the ability to process an item from the queue opens it pushes that item to be processed which runs the function.

--

--