Component communication React Questions
Master component communication react interviews with our comprehensive collection of 10 questions and challenges.
Pass callback functions from parent to child as props to enable child-to-parent communication in React.
Set fallback values for optional props using destructuring defaults in functional components and understand when to use defaultProps.
Use a controlled radio group with useState to capture the selected value and reflect it in another element.
Use controlled inputs with useState to mirror user-typed text into another element in real time.
Understand React synthetic events, event delegation, common patterns for handlers, and how to prevent default behavior and stop propagation.
Pass any JavaScript value from parent to child as props, understand how props flow in React, and know what children can and cannot do with them.
Understand what the Context API provides, what Redux adds on top of it, and how to decide which to reach for in a given situation.
Build a typed context with createContext, a Provider that holds state, and a custom hook for safe consumption.
Use forwardRef with useImperativeHandle to expose imperative methods from a child component, or use controlled props to manage disabled state from the parent.
Understand why prop drilling is a maintainability problem and know the four solutions: component composition, Context, state managers, and custom hooks.