Skip to content

Commit

Permalink
Merge pull request #6 from isdi-coders-2023/feature/add-router-and-pr…
Browse files Browse the repository at this point in the history
…ovider

Add router and provider
  • Loading branch information
barbara28bgb authored Oct 30, 2023
2 parents ac56efa + 19f77ee commit 188cb9a
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 3 deletions.
12 changes: 11 additions & 1 deletion src/components/App/App.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
import { Route, Routes } from "react-router-dom";

const App = (): React.ReactElement => {
return <main className="main-content"></main>;
return (
<>
<main className="main-content>">
<Routes>
<Route path="/home" />
</Routes>
</main>
</>
);
};

export default App;
8 changes: 6 additions & 2 deletions src/main.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
import React from "react";
import ReactDOM from "react-dom/client";
import App from "./components/App/App";
import { BrowserRouter } from "react-router-dom";

ReactDOM.createRoot(document.getElementById("root")!).render(
<React.StrictMode>
<div />
</React.StrictMode>
<BrowserRouter>
<App />
</BrowserRouter>
</React.StrictMode>,
);

0 comments on commit 188cb9a

Please sign in to comment.