Learn how to transform static components into a dynamic app using routes, Links, and dynamic parameters for a smooth Home-to-Episode transition.

React Router is the 'brain' that gives your application the ability to speak 'URL,' allowing you to swap components and update the address bar without the browser ever needing to refresh.
Explain React Router basics: routes, Link, useParams, navigating programmatically. Use Home and Episode details page example. No long config code.


A standard HTML anchor tag causes the browser to request a new page from the server, which triggers a full page refresh and clears the current React state. In contrast, the React Router Link component intercepts the click and uses the HTML5 History API to update the URL without refreshing the page. This allows the application to swap components nearly instantaneously, maintaining the "Single Page Application" experience and preserving the app's internal state.
Dynamic routing allows a single route to handle multiple paths by using a colon followed by a variable name, such as path="/episode/:id". This colon tells React Router that the segment is a placeholder that can match any value, such as /episode/1 or /episode/42. To access this specific value within a component, you use the useParams hook, which returns an object where the key matches the name defined in the route.
You should use the Link component for standard user-initiated navigation, like clicking a menu item or a list entry. You should use the useNavigate hook for "programmatic navigation," which occurs as a side effect of an action. Common examples include redirecting a user to a dashboard after a successful form submission, sending them to a login page if they lack permissions, or creating a "Go Back" button that moves through the browser's history.
React Router treats every part of a URL as a string, even if it looks like a number in the address bar. If you use useParams to grab an ID of "42" and try to compare it to a numeric value using strict equality, the comparison will fail due to the type mismatch. Developers must manually convert these parameters using functions like Number() or parseInt() if they need to perform mathematical operations or match the data against numeric database IDs.
By default, navigating to a new route adds a new entry to the browser's history stack, allowing the user to click the "Back" button to return to the previous screen. The replace: true option replaces the current entry in the history instead of adding a new one. This is particularly useful for login redirects or search filters, as it prevents "back-button loops" where a user is forced to click "Back" multiple times to skip over temporary states or redirected forms.
Cree par des anciens de Columbia University a San Francisco
"Instead of endless scrolling, I just hit play on BeFreed. It saves me so much time."
"I never knew where to start with nonfiction—BeFreed’s book lists turned into podcasts gave me a clear path."
"Perfect balance between learning and entertainment. Finished ‘Thinking, Fast and Slow’ on my commute this week."
"Crazy how much I learned while walking the dog. BeFreed = small habits → big gains."
"Reading used to feel like a chore. Now it’s just part of my lifestyle."
"Feels effortless compared to reading. I’ve finished 6 books this month already."
"BeFreed turned my guilty doomscrolling into something that feels productive and inspiring."
"BeFreed turned my commute into learning time. 20-min podcasts are perfect for finishing books I never had time for."
"BeFreed replaced my podcast queue. Imagine Spotify for books — that’s it. 🙌"
"It is great for me to learn something from the book without reading it."
"The themed book list podcasts help me connect ideas across authors—like a guided audio journey."
"Makes me feel smarter every time before going to work"
Cree par des anciens de Columbia University a San Francisco
