devblog/astro.config.ts

43 lines
1.1 KiB
TypeScript
Raw Normal View History

2024-12-25 02:14:10 -05:00
import { defineConfig } from "astro/config";
2025-03-08 19:45:21 -05:00
import tailwindcss from "@tailwindcss/vite";
import sitemap from "@astrojs/sitemap";
2024-12-25 02:14:10 -05:00
import remarkToc from "remark-toc";
import remarkCollapse from "remark-collapse";
import { SITE } from "./src/config";
2025-04-19 19:31:46 -04:00
import expressiveCode from "astro-expressive-code";
2024-12-25 02:14:10 -05:00
// https://astro.build/config
export default defineConfig({
site: SITE.website,
2025-05-17 21:18:28 -04:00
integrations: [
sitemap({
filter: (page) => SITE.showArchives || !page.endsWith("/archives"),
}),
expressiveCode(),
],
2024-12-25 02:14:10 -05:00
markdown: {
2025-03-08 19:45:21 -05:00
remarkPlugins: [remarkToc, [remarkCollapse, { test: "Table of contents" }]],
2024-12-25 02:14:10 -05:00
shikiConfig: {
// For more themes, visit https://shiki.style/themes
2025-05-17 21:18:28 -04:00
themes: { light: "catppuccin-latte", dark: "catppuccin-frappe" },
2024-12-25 02:14:10 -05:00
wrap: true,
},
},
vite: {
2025-03-08 19:45:21 -05:00
plugins: [tailwindcss()],
2024-12-25 02:14:10 -05:00
optimizeDeps: {
exclude: ["@resvg/resvg-js"],
},
},
2025-03-08 19:45:21 -05:00
image: {
// Used for all Markdown images; not configurable per-image
// Used for all `<Image />` and `<Picture />` components unless overridden with a prop
2025-05-17 21:18:28 -04:00
experimentalLayout: "full-width",
2025-03-08 19:45:21 -05:00
},
2025-01-19 21:33:22 -05:00
experimental: {
2025-03-08 19:45:21 -05:00
responsiveImages: true,
2025-01-19 21:33:22 -05:00
},
2025-05-17 21:18:28 -04:00
});