From d2963477450ec573ad2eae5bb8d50ee53caf3b30 Mon Sep 17 00:00:00 2001 From: Adrian Delgado Date: Mon, 5 Aug 2024 12:26:12 -0500 Subject: [PATCH] Refactor Navbar --- src/lib/components/layout/Navbar.svelte | 37 +++++++++++++++++++++++++ src/routes/+layout.svelte | 6 ++-- src/routes/components/Navbar.svelte | 34 ----------------------- 3 files changed, 40 insertions(+), 37 deletions(-) create mode 100644 src/lib/components/layout/Navbar.svelte delete mode 100644 src/routes/components/Navbar.svelte diff --git a/src/lib/components/layout/Navbar.svelte b/src/lib/components/layout/Navbar.svelte new file mode 100644 index 0000000..83d28eb --- /dev/null +++ b/src/lib/components/layout/Navbar.svelte @@ -0,0 +1,37 @@ + + + diff --git a/src/routes/+layout.svelte b/src/routes/+layout.svelte index 5f88a65..83ea84c 100644 --- a/src/routes/+layout.svelte +++ b/src/routes/+layout.svelte @@ -2,7 +2,8 @@ import "../app.postcss"; import { Toaster } from "svelte-sonner"; import { page } from "$app/stores"; - import Navbar from "./components/Navbar.svelte"; + import Navbar from "$lib/components/layout/Navbar.svelte"; + let { children } = $props(); @@ -12,6 +13,5 @@ - - {@render children()} + diff --git a/src/routes/components/Navbar.svelte b/src/routes/components/Navbar.svelte deleted file mode 100644 index 042367a..0000000 --- a/src/routes/components/Navbar.svelte +++ /dev/null @@ -1,34 +0,0 @@ - - -