fix: remove Font component and fontProviders (esbuild parse error)

The Font component with spread syntax caused esbuild parse error
at Base.astro line 64. Replaced with direct Google Fonts link tag.

Also removed fonts[] array from astro.config.mjs since we're
loading Inter via <link> tag instead.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Kunthawat Greethong
2026-05-01 10:18:59 +07:00
parent 065d92636a
commit b6e76cc98b
7 changed files with 95 additions and 12 deletions

View File

@@ -1,7 +1,7 @@
import node from "@astrojs/node";
import react from "@astrojs/react";
import icon from "astro-iconset";
import { defineConfig, fontProviders } from "astro/config";
import { defineConfig } from "astro/config";
import emdash, { local } from "emdash/astro";
import { sqlite } from "emdash/db";
@@ -44,14 +44,5 @@ export default defineConfig({
}),
}),
],
fonts: [
{
provider: fontProviders.google(),
name: "Inter",
cssVariable: "--font-sans",
weights: [400, 500, 600, 700, 800],
fallbacks: ["sans-serif"],
},
],
devToolbar: { enabled: false },
});