
Why react is called single page application?
React is called a Single Page Application because it loads a single HTML page and dynamically updates the UI using client-side rendering and virtual DOM without reloading the entire page. images.openai.com Why React is SPA (core reason) React uses Client-Side Rendering (CSR) Browser loads: index.html JavaScript bundle After that β React controls everything π No need to request a new HTML page from server every time Virtual DOM (the real engine) React doesnβt touch the real DOM directly every time. Instead: Creates a Virtual DOM Compares old vs new (diffing) Updates only the changed parts π This is why it feels fast and no reload happens Routing without reload (important) Libraries like: react-router-dom They change the URL, but: Do NOT reload the page Just swap components Example: < Route path = "/about" element = { < About /> } /> π Clicking /about does NOT fetch a new page π It just renders inside the same page
Continue reading on Dev.to React
Opens in a new tab




