diff --git a/public/favicon.ico b/public/favicon.ico
new file mode 100644
index 00000000..f9e7a94c
Binary files /dev/null and b/public/favicon.ico differ
diff --git a/public/favicon.svg b/public/favicon.svg
deleted file mode 100644
index 0f390629..00000000
--- a/public/favicon.svg
+++ /dev/null
@@ -1,13 +0,0 @@
-
diff --git a/src/components/Card.astro b/src/components/Card.astro
index e36b8f09..859412c8 100644
--- a/src/components/Card.astro
+++ b/src/components/Card.astro
@@ -8,9 +8,9 @@ export interface Props {
const { href, title, body } = Astro.props
---
-
+
-
+
{title}
→
@@ -19,45 +19,3 @@ const { href, title, body } = Astro.props
-
diff --git a/src/components/SEOMeta.astro b/src/components/SEOMeta.astro
index 5a7e882c..3fd181b2 100644
--- a/src/components/SEOMeta.astro
+++ b/src/components/SEOMeta.astro
@@ -1,12 +1,12 @@
---
interface Props {
title: string
- description: string | undefined
- favicon: string | undefined
- faviconMimeType: string | undefined
- keywords: string | undefined
- author: string | undefined
- robots: string | undefined
+ description?: string
+ favicon?: string
+ faviconMimeType?: string
+ keywords?: string
+ author?: string
+ robots?: string
}
const {
diff --git a/src/configs/site.ts b/src/configs/site.ts
new file mode 100644
index 00000000..81f02f80
--- /dev/null
+++ b/src/configs/site.ts
@@ -0,0 +1,7 @@
+export default {
+ title: 'LeetCode Blog',
+ description: 'Solutions for LeetCode problems - Written by ansidev',
+ author: 'ansidev',
+ favicon: '/favicon.ico',
+ faviconMimeType: 'image/ico',
+}
diff --git a/src/layouts/AppLayout.astro b/src/layouts/AppLayout.astro
new file mode 100644
index 00000000..32ee3a28
--- /dev/null
+++ b/src/layouts/AppLayout.astro
@@ -0,0 +1,28 @@
+---
+import SEOMeta from '@/components/SEOMeta.astro'
+import siteConfig from '@/configs/site'
+
+export interface Props {
+ title: string
+ description: string
+ author: string
+}
+
+const { title, author } = Astro.props
+const { favicon, faviconMimeType } = siteConfig
+---
+
+
+
+
+
+
+
+
+
+
diff --git a/src/layouts/Layout.astro b/src/layouts/Layout.astro
deleted file mode 100644
index 575e9caa..00000000
--- a/src/layouts/Layout.astro
+++ /dev/null
@@ -1,40 +0,0 @@
----
-export interface Props {
- title: string
-}
-
-const { title } = Astro.props
----
-
-
-
-
-
-
-
-
- {title}
-
-
-
-
-
-
diff --git a/src/pages/index.astro b/src/pages/index.astro
index c66ff95b..b1fc4987 100644
--- a/src/pages/index.astro
+++ b/src/pages/index.astro
@@ -1,17 +1,16 @@
---
import Card from '@/components/Card.astro'
-import Layout from '@/layouts/Layout.astro'
+import siteConfig from '@/configs/site'
+import AppLayout from '@/layouts/AppLayout.astro'
+
+const { title, description, author } = siteConfig
---
-
-
- Welcome to Astro
-
- To get started, open the directory src/pages
in your project.
-
- Code Challenge: Tweak the "Welcome to Astro" message above.
-
-
+
+
+ {title}
+ {description}
+
-
-
-
+