Interview Prep: React
Posted on Dec 25, 2020
- Explain and demonstrate [useState, useRef, useEffect, useMemo, useContext].
- Is JS statically or dynamically typed language?
- Is Babel a compiler or a transpiler ?
- What does webpack do in a CRA project ?
- Why do we use state in react ?
- Re-render component when browser is resized.
- Prevent re-rendering of child components, when parent component is updated.
- Explain side-effects in react components.
- Uncontrolled vs controlled components.
- How to debug infinte rendering loop(useEffect, memo and profiler) ?
- Keys in react and why index of array shouldn’t be used as a key ?
- Some techniques to optimize React app.
- Render a simple component with and without using JSX.
- Advantages of virtual DOM ?
- Props in react.
- MVC vs MVT.
- Functional components vs Class components.
- What is a pure component in react and can functional componcomponentent be pure ?
- How to avoid prop drilling ?
- Pass data form parent->child and child->parent.
- Styling a react component.
- Conditional chaining in react.
- Need of are Higher Order Components ?
- Pros and cons(componentDidCatch(), getDerivedStateFromError()) of hooks.
- React router and its major components.