Skip to content

Commit

Permalink
Fix references to public folder assets (e.g. favicon).
Browse files Browse the repository at this point in the history
  • Loading branch information
mross-ua committed Nov 23, 2023
1 parent aa63d1d commit fa67813
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion app.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<script setup lang="ts">
import { navMenuItems, homeMenuItem } from '~~/data/nav'
const config = useRuntimeConfig();
const colorMode = useColorMode();
const isSidebarVisible = ref(false);
Expand Down Expand Up @@ -66,7 +67,7 @@ const menuPassThroughOptions = {
<div class="flex flex-col items-center min-h-screen">
<div class="flex justify-between items-center w-full p-1">
<RouterLink :to="homeMenuItem.to!" :title="homeMenuItem.label" class="inline-block p-2">
<img src="/favicon/favicon-32x32.png" :alt="homeMenuItem.label as string" />
<img :src="`${config.app.baseURL}favicon/favicon-32x32.png`" :alt="homeMenuItem.label as string" />
</RouterLink>

<Button
Expand Down
2 changes: 1 addition & 1 deletion nuxt.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ export default defineNuxtConfig({
{
rel: 'icon',
type: 'image/x-icon',
href: '/favicon/favicon.ico'
href: (process.env.NUXT_APP_BASE_URL || '/') + 'favicon/favicon.ico'
}
]
}
Expand Down

0 comments on commit fa67813

Please sign in to comment.