My personal website.
1---
2interface Props {
3 title: string;
4 banner?: string;
5 graph?: {
6 description: string;
7 type?: "website" | "article";
8 };
9}
10
11const title = "::" + Astro.props.title;
12const { banner = "https://entomoviscera.online/mainbanner.png" } = Astro.props;
13const { graph } = Astro.props;
14---
15
16<html lang="en">
17 <head>
18 <title>{title}</title>
19 <link rel="icon" type="image/svg+xml" href="/favicon.svg" />
20 <link
21 rel="alternate"
22 type="application/rss+xml"
23 title="entomoviscera.online"
24 href={new URL("rss.xml", Astro.site)}
25 />
26 <meta charset="utf-8" />
27 <meta name="viewport" content="width=device-width, initial-scale=1.0" />
28 <meta name="generator" content={Astro.generator} />
29 {
30 graph && (
31 <Fragment>
32 <meta name="description" content={graph.description} />
33 <meta property="og:title" content={title} />
34 <meta property="og:description" content={graph.description} />
35 <meta
36 property="og:url"
37 content=
38 {new URL(Astro.url.pathname.toString(), Astro.site)}
39 />
40 <meta property="og:type" content={graph.type ?? "website"} />
41 <meta property="og:image" content={banner} />
42 </Fragment>
43 )
44 }
45 <style is:global>
46 * {
47 padding: 0;
48 margin: 0;
49 }
50
51 img {
52 max-width: 100%;
53 }
54 </style>
55 </head>
56 <body>
57 <slot />
58 </body>
59</html>