Skip to main content
Journey Uncommon Logo
JourneyUncommon
mediumReactlazy and SuspenseSingle-choice MCQ

A component is lazily loaded with React.lazy and wrapped in a Suspense boundary. The module fails to load (e.g. a network error fetching the chunk). What happens to the Suspense fallback, and how do you recover gracefully?

const Profile = React.lazy(() => import('./Profile')); <Suspense fallback={<Spinner />}> <Profile /> </Suspense>