mirror of
https://github.com/alrayyes/wiki.git
synced 2024-11-23 03:56:23 +00:00
14 lines
278 B
TypeScript
14 lines
278 B
TypeScript
import { resolveToRoot } from "../path"
|
|
|
|
export interface HeaderProps {
|
|
title: string
|
|
slug: string
|
|
}
|
|
|
|
export function Component({ title, slug }: HeaderProps) {
|
|
const baseDir = resolveToRoot(slug)
|
|
return <header>
|
|
<h1><a href={baseDir}>{title}</a></h1>
|
|
</header>
|
|
}
|
|
|