
























AstroPaper v6 is a complete rewrite built on Astro v6, Tailwind CSS v4, and TypeScript v6. The internals have been rebuilt around Astro's new stable primitives while keeping the same minimal, clean look.
Read the full writeup: AstroPaper 6.0 blog post
SITE / constants.ts replaced by a single astro-paper.config.ts at the project root using defineAstroPaperConfig() for full IntelliSensesrc/data/blog/ to src/content/posts/; standalone pages moved to src/content/pages/defineCollection with type: "content" replaced by Astro's glob() loader in src/content.config.tsglob() loader replaces the old collection patternexperimental.fonts graduated to a top-level fonts key (#632)All configuration — site metadata, pagination, feature flags, social links, share links — lives in one file:
// astro-paper.config.ts export default defineAstroPaperConfig({ site: { url, title, description, author, lang, timezone }, posts: { perPage, perIndex, scheduledPostMargin }, features: { lightAndDarkMode, dynamicOgImage, showArchives, showBackButton, editPost, search }, socials: [...], shareLinks: [...], });
Posts can now use .mdx — embed components, JSX expressions, and imports. Both .md and .mdx are picked up automatically.
All internal links go through getRelativeLocaleUrl() and withBase helpers. Deploying to a subdirectory (e.g. /astro-paper) works out of the box.
All UI strings extracted to src/i18n/lang/en.ts. Adding a new language requires only a new file under src/i18n/lang/.
Color palette extended from 5 to 7 tokens in src/styles/theme.css, registered to Tailwind v4 via @theme inline. Two new tokens: --accent-foreground and --muted-foreground.
ClientRouter from lightAndDarkMode feature flag (#631)muted-foreground color contrast for a11y (#631)_components/ scoping — post-specific components live under pages/posts/[...slug]/_components/getStaticPaths, not per pagePostLayout.astro handles SEO/structured data only; post page logic lives in the page fileFull Changelog: v5.5.1...v6.0.0
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。