Skip to content

Commit

Permalink
Fixing favicon error and removing unnecessary code
Browse files Browse the repository at this point in the history
  • Loading branch information
petrovicz committed Apr 4, 2024
1 parent 274f95e commit 2a184cf
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 10 deletions.
8 changes: 0 additions & 8 deletions src/components/Navbar.astro
Original file line number Diff line number Diff line change
@@ -1,15 +1,7 @@
---
// const baseUrl = import.meta.env.BASE_URL;
// const hrefHome = `${baseUrl}`;
// const hrefSub = `${baseUrl}/subpage/`;
const hrefHome = "/";
const hrefSub = "/subpage/";
const currentPath = Astro.url.pathname;
console.log("");
console.log(`Current path is: ${currentPath}`);
console.log(`Home path is: ${hrefHome}`);
console.log(`Subpage path is: ${hrefSub}`);
---

<div class="navbar justify-around">
Expand Down
3 changes: 1 addition & 2 deletions src/layouts/Layout.astro
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
---
import Navbar from "../components/Navbar.astro";
const baseUrl = import.meta.env.BASE_URL;
---

<html lang="en">
<head>
<meta charset="utf-8" />
<link rel="icon" type="image/svg+xml" href=`${baseUrl}/favicon.svg` />
<link rel="icon" type="image/svg+xml" href="/favicon.svg" />
<meta name="viewport" content="width=device-width" />
<meta name="generator" content={Astro.generator} />
<meta name="description" content="Demonstrating PhotoSwipe inside Astro, with automatic image optimizations." />
Expand Down

0 comments on commit 2a184cf

Please sign in to comment.