Personal Site

Add Base template and make all pages use it. Rename [...slug].md to [...slug].astro

vielle.dev 175e6bd9 4400a4ac

verified
+78 -13
+21
src/components/Base.astro
··· 1 + --- 2 + interface Props { 3 + title?: string; 4 + } 5 + --- 6 + 7 + <html lang="en"> 8 + <head> 9 + <meta charset="utf-8" /> 10 + <link rel="icon" type="image/svg+xml" href="/favicon.svg" /> 11 + <meta name="viewport" content="width=device-width" /> 12 + <meta name="generator" content={Astro.generator} /> 13 + <title> 14 + {Astro.props.title ? `${Astro.props.title} | vielle.dev` : "vielle.dev"} 15 + </title> 16 + <slot name="head" /> 17 + </head> 18 + <body> 19 + <slot /> 20 + </body> 21 + </html>
+7
src/pages/404.astro
··· 1 + --- 2 + import Base from "/components/Base.astro"; 3 + --- 4 + 5 + <Base> 6 + <h1>404 Error</h1> 7 + </Base>
+18
src/pages/500.astro
··· 1 + --- 2 + import Base from "/components/Base.astro"; 3 + 4 + interface Props { 5 + error: unknown; 6 + } 7 + --- 8 + 9 + <Base> 10 + <h1>500 Error</h1> 11 + <p> 12 + { 13 + Astro.props.error instanceof Error 14 + ? Astro.props.error.message 15 + : "Unknown error: " + Astro.props.error 16 + } 17 + </p> 18 + </Base>
+7
src/pages/blog/[...slug].astro
··· 1 + --- 2 + import Base from "/components/Base.astro"; 3 + --- 4 + 5 + <Base> 6 + <h1>vielle.dev</h1> 7 + </Base>
src/pages/blog/[...slug].md

This is a binary file and will not be displayed.

+7
src/pages/blog/index.astro
··· 1 + --- 2 + import Base from "/components/Base.astro"; 3 + --- 4 + 5 + <Base> 6 + <h1>vielle.dev</h1> 7 + </Base>
+4 -13
src/pages/index.astro
··· 1 1 --- 2 - 2 + import Base from "/components/Base.astro"; 3 3 --- 4 4 5 - <html lang="en"> 6 - <head> 7 - <meta charset="utf-8" /> 8 - <link rel="icon" type="image/svg+xml" href="/favicon.svg" /> 9 - <meta name="viewport" content="width=device-width" /> 10 - <meta name="generator" content={Astro.generator} /> 11 - <title>vielle.dev</title> 12 - </head> 13 - <body> 14 - <h1>vielle.dev</h1> 15 - </body> 16 - </html> 5 + <Base> 6 + <h1>vielle.dev</h1> 7 + </Base>
+7
src/pages/rss.xml.ts
··· 1 + export function GET( 2 + { 3 + // params, request 4 + }, 5 + ) { 6 + return new Response(`RSS Feed!`); 7 + }
+7
src/pages/use.astro
··· 1 + --- 2 + import Base from "/components/Base.astro"; 3 + --- 4 + 5 + <Base> 6 + <h1>vielle.dev</h1> 7 + </Base>