scrimba
Learn React Router
React Router
Initial Deploy to Netlify
Go Pro!Bootcamp

Bootcamp

Study group

Collaborate with peers in your dedicated #study-group channel.

Code reviews

Submit projects for review using the /review command in your #code-reviews channel

Initial Deploy to Netlify
AboutCommentsNotes
Initial Deploy to Netlify
Expand for more info
index.jsx
run
preview
console
import React from 'react';
import ReactDOM from 'react-dom/client';
import { BrowserRouter, Routes, Route, Link } from "react-router-dom"
import Home from "./pages/Home"
import About from "./pages/About"

function App() {
return (
<BrowserRouter>
<header>
<Link className="site-logo" to="/">#VanLife</Link>
<nav>
<Link to="/about">About</Link>
</nav>
</header>
<Routes>
<Route path="/" element={<Home />} />
<Route path="/about" element={<About />} />
</Routes>
</BrowserRouter>
)
}

ReactDOM
.createRoot(document.getElementById('root'))
.render(<App />);
Console
/
-11:41