Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions astro.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import partytown from "@astrojs/partytown";
import prefetch from "@astrojs/prefetch";

// https://astro.build/config
import vercel from "@astrojs/vercel/static";
import vercel from "@astrojs/vercel/serverless";

// https://astro.build/config
export default defineConfig({
Expand All @@ -30,7 +30,7 @@ export default defineConfig({
partytown(),
prefetch(),
],
output: "static",
output: "server",
adapter: vercel({
analytics: true,
}),
Expand Down
3,554 changes: 3,554 additions & 0 deletions forem.swagger.json

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
"@types/react": "^18.0.21",
"@types/react-dom": "^18.0.6",
"astro": "^2.1.6",
"powered-by-vercel": "^1.1.0",
"react": "^18.0.0",
"react-dom": "^18.0.0",
"tailwindcss": "^3.0.24"
Expand Down
11 changes: 11 additions & 0 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions src/components/FormattedDate.astro
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@ const { date } = Astro.props;
---

<time
datetime={date.toISOString()}
datetime={new Date(date).toISOString()}
class="whitespace-nowrap italic text-slate-11"
>
{
date.toLocaleDateString("en-us", {
new Date(date).toLocaleDateString("en-us", {
year: "numeric",
month: "short",
day: "numeric",
Expand Down
8 changes: 7 additions & 1 deletion src/components/Header.astro
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
import HeaderLink from "./HeaderLink.astro";
import { LinkedinLogo, GithubLogo, TwitterLogo } from "@phosphor-icons/react";
import ThemeToggle from "./ThemeToggle";
import poweredByVercel from "powered-by-vercel/powered-by-vercel.svg";

export const prerender = true;
---

<header
Expand All @@ -18,7 +21,7 @@ import ThemeToggle from "./ThemeToggle";
<HeaderLink href="/">Home</HeaderLink>
<HeaderLink href="/blog">Blog</HeaderLink>
</nav>
<div class="mr-8 mb-4 flex w-full justify-center gap-4">
<div class="mr-8 flex w-full justify-center gap-4">
<HeaderLink href="https://github.com/maxphillipsdev" target="_blank">
<GithubLogo size={18} />
</HeaderLink>
Expand All @@ -32,4 +35,7 @@ import ThemeToggle from "./ThemeToggle";
<ThemeToggle client:load />
</HeaderLink>
</div>
<div class="mr-8 hidden w-full justify-center md:flex">
<img src={poweredByVercel} alt="Powered by vercel badge" />
</div>
</header>
1 change: 0 additions & 1 deletion src/components/HeaderLink.astro
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ const isActive = href === pathname || href === pathname.replace(/\/$/, "");
className,
{ "text-crimson-9": isActive },
]}
rel="prefetch"
{...props}
>
<slot />
Expand Down
29 changes: 0 additions & 29 deletions src/content/blog/gatsby-image-blur.mdx

This file was deleted.

6 changes: 3 additions & 3 deletions src/content/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { defineCollection, z } from "astro:content";
const blog = defineCollection({
// Type-check frontmatter using a schema
schema: z.object({
title: z.string().optional(),
title: z.string(),
description: z.string().optional(),
// Transform string to Date object
pubDate: z
Expand All @@ -14,8 +14,8 @@ const blog = defineCollection({
.string()
.optional()
.transform((str) => (str ? new Date(str) : undefined)),
heroImage: z.string().optional(),
draft: z.boolean().optional(),
coverImage: z.string().optional(),
tags: z.array(z.string()).optional(),
}),
});

Expand Down
Loading