mirror of
https://github.com/elk-zone/elk.git
synced 2024-11-25 18:56:37 +03:00
3b92b27cc8
Co-authored-by: Daniel Roe <daniel@roe.dev>
16 lines
510 B
TypeScript
16 lines
510 B
TypeScript
import { APP_NAME } from '~/constants'
|
|
|
|
const isDev = process.dev
|
|
const isPreview = window.location.hostname.includes('deploy-preview')
|
|
|
|
export function usePageHeader() {
|
|
useHead({
|
|
titleTemplate: title => `${title ? `${title} | ` : ''}${APP_NAME}${isDev ? ' (dev)' : isPreview ? ' (preview)' : ''}`,
|
|
link: [
|
|
{ rel: 'icon', type: 'image/svg+png', href: isDev || isPreview ? '/favicon-dev.png' : '/favicon.png' },
|
|
],
|
|
})
|
|
|
|
// eslint-disable-next-line no-unused-expressions
|
|
isDark.value
|
|
}
|