feat: change title path appearance
This commit is contained in:
parent
534abd91e3
commit
4abfef69d3
4 changed files with 15 additions and 6 deletions
|
@ -2,13 +2,18 @@
|
|||
import '../styles/global.css';
|
||||
import Search from '../components/Search.astro';
|
||||
import ThemeSwitcher from '../components/ThemeSwitcher.astro';
|
||||
import { siteConfig } from "../config";
|
||||
|
||||
interface Props {
|
||||
title: string;
|
||||
path?: string;
|
||||
}
|
||||
|
||||
const { title, path = "~/grassblock/micr0blog" } = Astro.props;
|
||||
const defaultTitle = siteConfig.title
|
||||
const formattedPath = defaultTitle.toLowerCase().replace(/\s+/g, '-');
|
||||
|
||||
const { title, path = formattedPath } = Astro.props;
|
||||
// TODO: make the path dynamic
|
||||
---
|
||||
|
||||
<!doctype html>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue