react dev only displays: Troubleshooting Rendering Issues
- Authors

- Name
- Geeks Kai
- @KaiGeeks
If part of a React page is missing in development, first identify what is absent: the whole application, one component, one data section or content that exists in the DOM but is hidden. “React dev only displays” is not a React error code, so it cannot identify a root cause on its own.

This guide is a diagnostic entry point for that symptom. The state example targets React 19.3 and requires an existing React application. It does not assume Vite, Next.js, a particular router or a production API.
Write down the expected section, the actual route, the action that should reveal it, browser and framework versions, and the first relevant Console or Network error. Compare a fresh navigation with client-side navigation if they differ. A screenshot alone cannot tell whether a component returned null, a request failed or CSS hid a rendered element.
| Observation | Check next |
|---|---|
| Root application is absent | Entry script, mount element, module/build errors and route response |
| Component has an exception | Stack trace and the first application-owned frame |
| Component exists but returns nothing | Conditional return, permissions and required props |
| Loading never ends | Request completion, rejection, cancellation and state transitions |
| Content exists in Elements | display/visibility, dimensions, overflow and stacking |
| Only direct route loading fails | Server deep-link routing and the framework/router setup |
Use React Developer Tools to inspect the relevant component's props and state. Browser Elements and Computed styles answer a different question: what DOM exists and how it is displayed. Use the profiler after identifying a slow interaction; performance work is not the first remedy for missing content.
React's conditional-rendering guide explains branches and null returns. A branch that deliberately returns null is different from a thrown exception. Read the values controlling the branch before changing its condition.
Save this complete module as DisplayStates.jsx and render its default export inside your existing application. The buttons select synthetic states; no network request or real authorization is implemented.
// file: DisplayStates.jsx
import { useState } from "react"
const DISPLAY_STATUS = Object.freeze({
LOADING: "loading",
FAILED: "failed",
EMPTY: "empty",
READY: "ready",
})
const DEMO_RECORDS = [{ id: "example-1", title: "Example article" }]
export function ContentPanel({ status, records }) {
if (status === DISPLAY_STATUS.LOADING) {
return <p role="status">Loading articles...</p>
}
if (status === DISPLAY_STATUS.FAILED) {
return <p role="alert">Articles could not be loaded.</p>
}
if (records.length === 0) {
return <p>No articles found.</p>
}
return <ul>{records.map(record => <li key={record.id}>{record.title}</li>)}</ul>
}
export default function DisplayStates() {
const [status, setStatus] = useState(DISPLAY_STATUS.LOADING)
const records = status === DISPLAY_STATUS.READY ? DEMO_RECORDS : []
return (
<section>
<h2>Article display states</h2>
{Object.values(DISPLAY_STATUS).map(nextStatus => (
<button key={nextStatus} onClick={() => setStatus(nextStatus)}>{nextStatus}</button>
))}
<ContentPanel status={status} records={records} />
</section>
)
}
Expected behavior: loading shows a status message, failed shows an alert, empty shows an empty-state message, and ready shows Example article. If the state reaches ready in your real application but content is absent, inspect the actual records and the next rendering boundary. This demonstration does not establish that any particular fetch or authentication service succeeds.
For a data-dependent section, inspect the HTTP result, body and validation separately. A fulfilled fetch promise does not imply an HTTP success. Show a request failure as a failure, rather than silently replacing it with an empty list. When a dependency changes or the component unmounts, an older response must not overwrite the current selection.
React's Effect documentation describes dependencies and cleanup. If the application already uses a framework loader or query library, inspect that library's loading/error/cache state instead of adding a second fetching mechanism. The SWR and Vite guide covers a separate data-fetching workflow.
An Error Boundary can show a fallback for descendant rendering failures. It does not automatically handle every rejected request, event-handler error or server response. A fallback appearing is evidence of a caught failure, not a completed repair.
If the DOM exists, inspect its computed style and bounding box before editing CSS. If a route fails only after refresh, inspect the server response and route configuration. Keep the original error visible until you can explain it; a full reload can hide a state or navigation defect.
Repeat the original route and action, then exercise loading, failure, empty and success. Test an out-of-order response when the bug involves rapid selection changes. Confirm visible content and the absence of the original error. Use the same development mode and dependency versions during comparison.
Adding useMemo or a custom memo comparator does not repair an incorrect condition or missing input. A comparator that ignores a relevant prop can itself preserve stale output. Keep performance optimization separate from this rendering diagnosis; the rendering and performance questions explain those boundaries.