summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTomasBankauskas <tbdizainas@gmail.com>2024-04-03 12:39:42 +0300
committerTomasBankauskas <tbdizainas@gmail.com>2024-04-03 12:39:42 +0300
commitbfbb307ee64f96cf4a75023b500579c833e461ce (patch)
tree4240ca75f2ca86c2dc4c4766985c5f3c7487d86b /src
initial commit
Diffstat (limited to 'src')
-rw-r--r--src/env.d.ts1
-rw-r--r--src/layouts/Layout.astro22
-rw-r--r--src/pages/index.astro13
3 files changed, 36 insertions, 0 deletions
diff --git a/src/env.d.ts b/src/env.d.ts
new file mode 100644
index 0000000..f964fe0
--- /dev/null
+++ b/src/env.d.ts
@@ -0,0 +1 @@
+/// <reference types="astro/client" />
diff --git a/src/layouts/Layout.astro b/src/layouts/Layout.astro
new file mode 100644
index 0000000..5c9eaae
--- /dev/null
+++ b/src/layouts/Layout.astro
@@ -0,0 +1,22 @@
+---
+interface Props {
+ title: string;
+}
+
+const { title } = Astro.props;
+---
+
+<!doctype html>
+<html lang="en">
+ <head>
+ <meta charset="UTF-8" />
+ <meta name="description" content="Astro description" />
+ <meta name="viewport" content="width=device-width" />
+ <link rel="icon" type="image/svg+xml" href="/favicon.svg" />
+ <meta name="generator" content={Astro.generator} />
+ <title>{title}</title>
+ </head>
+ <body>
+ <slot />
+ </body>
+</html> \ No newline at end of file
diff --git a/src/pages/index.astro b/src/pages/index.astro
new file mode 100644
index 0000000..cac48e0
--- /dev/null
+++ b/src/pages/index.astro
@@ -0,0 +1,13 @@
+---
+import Layout from '../layouts/Layout.astro';
+---
+
+<Layout title="Welcome to Astro.">
+ <main>
+ <h1>Welcome to Astro</h1>
+ <p>
+ To get started, open the directory <code>src/pages</code> in your project.<br />
+ <strong>Code Challenge:</strong> Tweak the "Welcome to Astro" message above.
+ </p>
+ </main>
+</Layout>