diff --git a/src/components/layout.tsx b/src/components/layout.tsx
new file mode 100644
index 0000000..a8ebe41
--- /dev/null
+++ b/src/components/layout.tsx
@@ -0,0 +1,14 @@
+import { Outlet } from "react-router-dom";
+
+export function Layout() {
+ return (
+
+
+
+
+
+
+ );
+}
diff --git a/src/router.tsx b/src/router.tsx
index 073f5b4..0aa7a31 100644
--- a/src/router.tsx
+++ b/src/router.tsx
@@ -3,23 +3,29 @@ import { Home } from "./pages/home";
import { Podcast } from "./pages/podcast";
import { Episode } from "./pages/episode";
import { PodcastEpisodesList } from "./components/podcast-episodes-list";
+import { Layout } from "./components/layout";
const router = createBrowserRouter([
{
- path: "/",
- element: ,
- },
- {
- path: "/podcast",
- element: ,
+ element: ,
children: [
{
- path: ":podcastId",
- element: ,
+ path: "/",
+ element: ,
},
{
- path: ":podcastId/episode/:episodeId",
- element: ,
+ path: "/podcast",
+ element: ,
+ children: [
+ {
+ path: ":podcastId",
+ element: ,
+ },
+ {
+ path: ":podcastId/episode/:episodeId",
+ element: ,
+ },
+ ],
},
],
},