React Interview Questions
What is react?
What are some of the features of react?
What's the difference between the real DOM and the virtual DOM?
React makes a virtual copy of the DOM to determine what parts of the actual DOM need to change based on a user’s actions. It then grabs the change date from the Virtual DOM and selectively updates the actual DOM (instead of reloading reloading the entire thing). Since this prevents constant page reloading, it create signification performance improvements.
- It updates slow.
- Can directly update HTML.
- Creates a new DOM if element updates.
- DOM manipulation is very expensive.
- Too much of memory wastage.
- Updates Faster
- Can’t directly update the HTML
- Update the JSX if the element updates
- DOM Manipulation is very easy
- No Memory Waste
What is JSX?
You don’t need to use JSX to buld websites with React, though it is a helpful tool.
What does render() do in React?
Class Components vs Functional Components?
What are Arrow Functions in React?
=>are a syntax for function expressions and are one of the ways to pass parameters to callback functions. Using an arrow function creates a new function each time the component renders.
What's the difference between ES5 and ES6?
What is Props in React?
Props (short for Properties) are read only components that are passed down from parent to child (maintaining the uni-directional data flow). They are immutable and mostly used to render dynamically created of gotten data – they describe the way a React component is configured.
Properties are set when instantiating the component, and they shouldn’t be mutated afterwards. Mutating values within a component are tracked with the
state property rather than the
What is State in React?
this.state(). State is facilitated with event handlers on DOM elements that notify the component of the new state with the updated values retrieved from the DOM (like when a user types in an input box for example). The state of a component can be updated with