Q51. How does useLayoutEffect work during server-side rendering (SSR)?
The `useLayoutEffect` hook does **not run on the server**, because there is no DOM. React issues a warning in server environments like Next.js if `useLayoutEffect` is use...
Technical Question Bank · Peer-Reviewed
Search and filter frequently asked interview questions across technical, programming, and behavioral domains. Tailor your interview preparation by difficulty for freshers or experienced developers (71 available).
The `useLayoutEffect` hook does **not run on the server**, because there is no DOM. React issues a warning in server environments like Next.js if `useLayoutEffect` is use...
Custom hooks allow you to **extract and share stateful logic** between components without changing their hierarchy. The state itself is not shared—each component using th...
`useEvent` is an **experimental hook** (not yet stable in React) designed to solve the problem of creating **stable event handlers** that always access the latest props a...
React 18, released in March 2022, introduced several groundbreaking features focused on performance and user experience: #### 1. **Automatic Batching** Batch multiple sta...
React 19 (released 2024) brings major improvements for full-stack React applications: #### 1. **React Compiler (formerly React Forget)** Automatic memoization - no more m...
The `use()` hook allows you to read the value of a resource (Promise or Context) during render, with Suspense integration. #### Reading Promises ```jsx import { use, Susp...
**Server Actions** allow you to call server-side functions directly from client components without writing API endpoints. #### Basic Server Action ```jsx // app/actions.j...
These hooks simplify form handling with Server Actions in React 19. #### useFormState Manages form state and handles server responses: ```jsx 'use client' import { useFor...
`useOptimistic` enables optimistic UI updates - showing changes immediately before server confirmation. #### Basic Usage ```jsx import { useOptimistic } from 'react'; fun...
The **React Compiler** (formerly known as React Forget) automatically optimizes your components by adding memoization where needed - eliminating the need for manual `useM...
HireXTech uses essential storage to remember your study preferences and third-party advertising cookies via Google AdSense in compliance with GDPR. You can choose to enable essential cookies only or accept all cookies. Read our Privacy Policy.