Question Bank
3705 approved questions from the community
Which of the following can be rendered in React 16+? (Select all that apply)
Which of the following are recommended practices when using keys? (Select all that apply)
Which of the following are benefits of TypeScript with React? (Select all that apply)
JSX must be transpiled before browsers can run it.
Using array indices as keys is always safe, even for reorderable lists.
Hooks can be called inside loops if the loop always has the same length.
`useRef` updates trigger rerenders by default.
Mutating React state directly is recommended for performance.
Hydration is attaching React behavior to server-rendered HTML on the client.
React Strict Mode can intentionally run some logic twice in development.
A Higher-Order Component takes a component and returns a new component.
Static generation is ideal for pages that change infrequently.
Copying props into state without clear need can create anti-patterns.
Virtual DOM is an in-memory representation used to compute efficient real DOM updates.
Reconciliation is React's diffing process to decide what to update in the UI.
Props can be modified by the child component that receives them.
React.memo() performs a deep comparison of props by default.
The children prop can only contain React elements.
Custom hooks must follow the same rules as built-in hooks, including starting with 'use' prefix.
React automatically binds event handlers in class components.