import { defineConfig } from "astro/config"; import { unified } from "@astrojs/markdown-remark"; import starlight from "@astrojs/starlight"; import { docsSidebarGroups } from "./src/lib/docs-sidebar"; import { remarkRepoLinks } from "./src/lib/remark-repo-links"; import { repoUrl } from "./src/lib/forge"; import { readRelease } from "./src/lib/repo"; export default defineConfig({ site: "https://nxdns.sh", trailingSlash: "always", markdown: { processor: unified({ remarkPlugins: [remarkRepoLinks] }) }, vite: { define: { __NXDNS_RELEASE__: JSON.stringify(readRelease()) } }, integrations: [ starlight({ title: "nxdns", description: "A DNS sinkhole for your LAN.", favicon: "/favicon.svg", // ZON is Zig's literal syntax; Shiki ships no grammar under its own name. expressiveCode: { shiki: { langAlias: { zon: "zig" } } }, social: [{ icon: "seti:git", label: "Source", href: repoUrl }], customCss: ["./src/styles/fonts.css", "./src/styles/tokens.css", "./src/styles/starlight.css"], components: { SiteTitle: "./src/components/starlight/SiteTitle.astro", ThemeProvider: "./src/components/starlight/ThemeProvider.astro", ThemeSelect: "./src/components/starlight/ThemeSelect.astro", }, sidebar: [{ label: "Overview", link: "/docs/" }, ...docsSidebarGroups(), { label: "Changelog", link: "/changelog/" }], }), ], });