31 lines
463 B
TypeScript
31 lines
463 B
TypeScript
interface NavItem {
|
|
label: string
|
|
to: string
|
|
}
|
|
|
|
interface SiteContent {
|
|
identity: {
|
|
name: string
|
|
description: string
|
|
url: string
|
|
}
|
|
navigation: NavItem[]
|
|
footer: {
|
|
credits: string
|
|
links: NavItem[]
|
|
}
|
|
gratewizard: {
|
|
url: string
|
|
popup: {
|
|
width: number
|
|
height: number
|
|
}
|
|
}
|
|
}
|
|
|
|
export function useSiteContent() {
|
|
return useAsyncData<SiteContent>('site-content', () =>
|
|
$fetch('/api/content/site'),
|
|
)
|
|
}
|