仅使用 Astro 与原生 CSS,不引入 UI 框架或 CSS 框架,依赖精简
astro-erudite — Astro 作品集模板
作者 jktrn
astro-erudite 是一个基于 Astro 与原生 CSS 的静态博客模板,不使用 UI 框架和 CSS 框架,依赖精简,适合搭建以 Markdown 写作、强调排版与阅读体验的个人站点。
看看你的网站会是什么样
浏览真实页面截图,比较内容排版与手机效果。点击下方缩略图切换,放大查看整页细节。
全部页面与视图 3
截图用于了解视觉与布局,交互效果请以实际项目为准。
值得关注的模板亮点
从已有项目资料中,快速了解它的特点。
设计系统基于 autonomous custom elements 与 Utopia 流式字号、间距比例
Markdown 由 Sätteri 处理,代码块使用 Expressive Code,数学公式经 Temml 渲染为 MathML
支持系列文章(subposts)、多作者档案、标签页、RSS 与站点地图
文章 frontmatter 由 Zod schema 校验,含标题、描述、日期、作者等字段
模板详细介绍
astro-erudite 由 enscribe 开发,是一个带有明确设计取向的静态博客模板,使用 Astro 和原生 CSS 构建,不引入 UI 框架或 CSS 框架,依赖数量较少。模板提供博客文章、作者档案、标签页、RSS 订阅与站点地图等基础内容结构,并支持多作者、系列文章(subposts)和可点击的标题锚点。
在排版与内容呈现方面,模板使用原生 CSS 构建设计系统,基于 autonomous custom elements 与 Utopia 的流式字号、间距比例;Markdown 由 Sätteri 处理,代码块使用 Expressive Code,数学公式通过 Temml 渲染为 MathML。站点配置集中在 src/consts.ts,颜色定义在 src/styles/color.css,使用 Radix Colors 色阶并通过 light-dark() 提供明暗配对。
使用限制:模板定位为无预设样式的静态博客起点,不包含 UI 组件库或 CSS 框架;内容以 Markdown 文件形式存放在 src/content/blog/ 目录,文章 frontmatter 需符合其 Zod schema(如 title、description、date、authors 为必填)。演示图片、字体、图标等第三方素材需单独核对许可。
适合你的项目吗?
适用场景
- 搭建以 Markdown 写作为主的个人博客或技术博客
- 需要多作者协作、作者档案页与文章标签分类的内容站点
- 发布系列文章并希望以连续滚动文档形式呈现
- 需要 RSS 订阅、站点地图和 Open Graph 元数据控制的静态站点
适合人群
- 熟悉 Astro 与 Markdown 内容集合的开发者
- 希望从无预设样式的模板开始自行设计视觉风格的个人
- 需要轻量依赖、以内容阅读为核心的博客项目
- 有数学公式或代码高亮展示需求的技术写作者
上手与定制指南
结合仓库当前版本的说明,按下面的资料检查内容、配置与运行要求。
- 1
通过 GitHub 的 Use this template 创建仓库后克隆,使用 bun install 安装依赖,bun dev 启动开发服务器
- 2
站点元数据、导航链接与社交链接在 src/consts.ts 中配置,生产 URL 在 astro.config.ts 的 site 字段设置
- 3
颜色在 src/styles/color.css 中基于 Radix Colors 色阶定义,通过 light-dark() 提供明暗配对
- 4
博客文章以 Markdown 文件放入 src/content/blog/,frontmatter 需符合模板定义的 Zod schema
- 5
替换 public/ 目录下的 favicon 文件后,需同步调整 src/components/MetaHead.astro 中的引用
授权与来源资料
使用条件与限制
免费使用 · 保留许可声明本次收录的是公开仓库中采用 MIT 许可的免费版本;免费范围为该版本代码,不代表外部服务或第三方素材免费。
使用时需要遵守
- 允许免费使用、修改、商用和分发该版本代码。
- 分发代码副本或实质性部分时,保留原作者版权声明和完整 MIT 许可声明。
- 代码按现状提供;担保与责任限制以原许可证及适用法律为准。
额外费用与待核对事项
- 演示图片、字体、图标及其他第三方素材需按各自许可核对,不能仅凭代码的 MIT 许可判断。
- 域名、托管、数据库、支付或 AI 等外部服务可能另外收费。
查看原文依据
https://github.com/jktrn/astro-erudite/blob/main/LICENSEhttps://github.com/jktrn/astro-erudite/blob/main/README.mdPermission is hereby granted, free of charge
许可证原文
DeepSeek 根据仓库许可证和 README 整理 ·2026-10-04。结果仅覆盖已读取资料,依赖、图片、字体及后续条款变更以各自原文为准。
项目核对记录与介绍依据
模板资料
- 来源平台
- Astro Themes
- 资料与维护参考分
- 资料较完整 · 96 / 100
- 技术栈
- Astro
- 网站类型
- 作品集 · 博客 · 启动器
这个分数如何计算
本站按许可资料(最高30分)、演示链接(12分)、预览图(10分)、Star数(15分)、记录的维护时间(15分)、描述完整度(8分)、功能记录(5分)和分类资料(5分)计算。它不是代码、安全或性能测试,也不是 Google 评分;有链接不代表已实测可用。
这个项目需要核对什么
- 记录的仓库更新时间
- 2026-07-27
- 截图检查日期
- 2026-10-04
已收录演示链接。请用你的内容与屏幕尺寸检查;有演示不代表表单、认证或支付已经可用。
目录记录的主要技术栈是 Astro。请通过依赖清单和锁文件核对实际版本与托管要求。这些说明基于收录资料,不代表代码审计或部署实测。
查看具体选型方法 →介绍的制作与核对状态
介绍由 AI 辅助整理目录与仓库资料。仓库作者不等于这篇介绍的审核者。
审核声明: [email protected] · 2026-10-04
查看当时使用的来源资料
SHA-256: 38b4b2fa5037ac59131e1bed6639e8449d5e58ecfc737a66c7e2831128fa8caf
2026-10-04T10:46:06.585Z
来源文件 / 仓库
<div align="center">
## astro-erudite
![Stargazers]
![Astro Version]
![Dependencies]
[![License]](LICENSE)
</div>
astro-erudite is [enscribe](https://enscribe.dev)'s opinionated, unstyled static blogging template built with [Astro](https://astro.build/) and native CSS. astro-erudite uses no UI framework, no CSS framework, and contains minimal dependencies.
|  |  |
| ------------------------------------------ | ------------------------------------------ |
|  |  |
> [!IMPORTANT]
> astro-erudite has recently been updated to v2. To learn what changed and why, read the following blog post: [Introducing astro-erudite v2](https://astro-erudite.vercel.app/blog/introducing-v2). If you're migrating an existing v1 project, see [breaking changes](https://astro-erudite.vercel.app/blog/introducing-v2#breaking-changes).
---
## Community examples
Below are some fantastic examples of websites based on this template. If you wish to add your site to this list, open a [pull request](https://github.com/jktrn/astro-erudite/pulls)!
| Site | Author | Tags | Source |
|-|-|-|-|
| [enscribe.dev](https://enscribe.dev) | [@jktrn](https://github.com/jktrn) | portfolio, interactive | [→](https://github.com/jktrn/enscribe.dev) |
| [emile.sh](https://emile.sh) | [@echoghi](https://github.com/echoghi) | minimal, flexoki | [→](https://github.com/echoghi/v5) |
| [decentparadox.me](https://decentparadox.me) | [@decentparadox](https://github.com/decentparadox) | portfolio, sci-fi | [→](https://github.com/decentparadox/decentparadox.me) |
| [flocto.github.io](https://flocto.github.io/) | [@flocto](https://github.com/flocto) | blog | [→](https://github.com/flocto/flocto.github.io) |
| [dumbprism.me](https://www.dumbprism.me/) | [@dumbprism](https://github.com/dumbprism) | portfolio, bento | [→](https://github.com/dumbprism/dumbprism-portfolio) |
| [hyuki.dev](https://hyuki.dev/) | [@snow0406](https://github.com/snow0406) | minimal, blog | [→](https://github.com/Snow0406/hyuki.dev) |
| [ldd.cc](https://ldd.cc/) | [@xJoyLu](https://github.com/xjoylu) | blog | [→](https://ldd.cc/) |
| [rezarezvan.com](https://rezarezvan.com/) | [@rezaarezvan](https://github.com/rezaarezvan) | academic, blog | [→](https://rezarezvan.com/) |
| [blog.z0x.ca](https://blog.z0x.ca/) | [@z0x](https://z0x.ca) | minimal | [→](https://git.z0x.ca/z0x/blog.z0x.ca/) |
| [angelaytchan.net](https://angelaytchan.net/) | [@wispyplant](https://github.com/wispyplant) | portfolio, art | [→](https://github.com/wispyplant/wispyplant.github.io) |
| [kaezr.xyz](https://kaezr.xyz/) | [@kaezrr](https://github.com/kaezrr) | minimal, portfolio | [→](https://github.com/kaezrr/webfolio) |
| [worldwidewong](https://worldwidewong.vercel.app) | [@brendanwong-web](https://github.com/brendanwong-web) | portfolio, gallery | [→](https://github.com/brendanwong-web/worldwidewong) |
| [bgajjala.dev](https://bgajjala.dev) | [@bgajjala8](https://github.com/bgajjala8) | minimal, blog | [→](https://github.com/bgajjala8/bgajjala.dev) |
| [ankitz007.vercel.app](https://ankitz007.vercel.app) | [@ankitz007](https://github.com/ankitz007) | blog | [→](https://github.com/ankitz007/webfolio) |
| [sadman.ca](https://sadman.ca) | [@sadmanca](https://github.com/sadmanca) | blog, media | [→](https://github.com/sadmanca/blogv3) |
| [marcel-to.vercel.app](https://marcel-to.vercel.app) | [@Marcel-TO](https://github.com/Marcel-TO) | portfolio, docs | [→](https://github.com/Marcel-TO/marcel-to-website) |
| [merox.dev](https://merox.dev) | [@meroxdotdev](https://github.com/meroxdotdev) | blog, devops, homelab | [→](https://github.com/meroxdotdev/merox) |
| [Off by One](https://justoffbyone.com) | [@cduruk](https://github.com/cduruk) | engineering, blog | [→](https://github.com/cduruk/offbyone) |
| [holywater.dev](https://holywater.dev) | [@holywater2372](https://github.com/holywater2372) | cybersecurity, blog | [→](https://github.com/holywater2372/holywater.dev) |
| [theinfinull.com](https://theinfinull.com) | [@theinfinull](https://github.com/theinfinull) | dev, portfolio, blog | [→](https://github.com/theinfinull/portfolio) |
| [chai-pin-zheng.xyz](https://www.chai-pin-zheng.xyz/) | [@Ducksss](https://github.com/Ducksss) | portfolio, interactive, blog, ascii | [→](https://github.com/Ducksss/ascii-astro-erudite) |
| [nightxade.dev](https://nightxade.dev) | [@nightxade](https://github.com/nightxade) | blog, portfolio | [→](https://github.com/nightxade/nightsite)
| [xingpingcn.top](https://xingpingcn.top) | [@xingpingcn](https://github.com/xingpingcn) | blog, chinese | [→](https://github.com/xingpingcn/newblog) |
## Features
- A design system built entirely on native CSS, using [autonomous custom elements](https://developer.mozilla.org/en-US/docs/Web/API/Web_components/Using_custom_elements) and [Utopia](https://utopia.fyi/) fluid type and space scales.
- The ridiculously fast [Sätteri](https://satteri.bruits.org/) Markdown processor (written in Rust)
- [Expressive Code](https://expressive-code.com/) for code blocks and inline code, with `` `code{:lang}` `` annotations and TextMate scope highlighting.
- $\LaTeX$ math rendered to browser-native and lightweight [MathML](https://developer.mozilla.org/en-US/docs/Web/MathML) via [Temml](https://temml.org/).
- Subposts for organizing series, rendered as one continuous scrollable document.
- A fully responsive table of contents with active scrollspy highlighting.
- Clickable heading anchors for permalinking to any section.
- GitHub-style callouts/alerts via `:::` directives.
- SEO optimization with granular metadata and [Open Graph](https://ogp.me/) tag control for each post.
- [RSS](https://en.wikipedia.org/wiki/RSS) feed and sitemap generation.
- Author profiles with a dedicated authors page and multi-author post support.
- Post tags with a dedicated tags page for categorization and discovery.
## Getting started
1. Hit “Use this template”, the big green button on the top right, to create a new repository in your own GitHub account with this template.
2. Clone the repository:
```bash
git clone https://github.com/[YOUR_USERNAME]/[YOUR_REPO_NAME].git
cd [YOUR_REPO_NAME]
```
3. Install dependencies:
```bash
bun install
```
4. Start the development server:
```bash
bun dev
```
5. Open your browser and visit `http://localhost:4321` to get started. The following commands are also available:
| Command | Description |
| ---------------------- | ------------------------------------------------- |
| `bun run build` | Build the production site to `dist/` |
| `bun run preview` | Preview the built project locally |
| `bun run astro` | Run Astro CLI commands |
| `bun run format` | Format all files using [Biome](https://biomejs.dev/) |
| `bun run format:check` | Check formatting without writing |
### Site configuration
Edit the `src/consts.ts` file to update your site's metadata, navigation links, and social links:
```ts
export const SITE = {
title: "astro-erudite",
description: "An opinionated, unstyled blogging template built with Astro.",
locale: "en-US",
dir: "ltr",
defaultPageImage: "/static/opengraph-image.png",
defaultPostImage: "/static/1200x630.png",
} as const
export const NAVIGATION = [
{ href: "/blog", label: "Blog" },
// ...
]
export const SOCIALS: { href: string; label: string; icon: SvgComponent }[] = [
{ href: "https://github.com/jktrn", label: "GitHub", icon: GitHub },
// ...
]
```
Your site's production URL is configurable in `astro.config.ts` as the `site` field, which is used for the sitemap, RSS feed, and canonical URLs.
### Color palette
Colors are defined in `src/styles/color.css` using the [Radix Colors](https://www.radix-ui.com/colors) scales. Each step carries a light/dark pair via [`light-dark()`](https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Values/color_value/light-dark) and the semantic tokens point at the scale, so the site respects system preference out of the box and the theme toggle only stores an override:
```css
:root {
--gray-1: light-dark(#fcfcfc, #111111);
/* ... */
--gray-12: light-dark(#202020, #eeeeee);
--background: var(--gray-1);
--foreground: var(--gray-12);
--muted-foreground: var(--gray-11);
--border: var(--gray-6);
/* ... */
color-scheme: light dark;
}
```
### Favicons
Favicons are generated using [RealFaviconGenerator](https://realfavicongenerator.net/). To adjust the favicons, replace the files in the `public/` directory (such as `favicon.ico`, `favicon.svg`, `apple-touch-icon.png`, etc.) with your own. After updating the favicon files, you'll also need to adjust the references in `src/components/MetaHead.astro` to match your new favicon filenames and paths:
```html
<!-- Replace these with the generated meta tags -->
<link rel="icon" type="image/png" href="/favicon-96x96.png" sizes="96x96" />
<link rel="icon" type="image/svg+xml" href="/favicon.svg" />
<link rel="shortcut icon" href="/favicon.ico" />
<link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png" />
<meta name="apple-mobile-web-app-title" content="astro-erudite" />
<link rel="manifest" href="/site.webmanifest" />
```
## Adding content
### Blog posts
Add new blog posts as Markdown files in the `src/content/blog/` directory, either as a bare `your-post.md` or as a `your-post/index.md` folder (which lets you colocate assets). Use the following frontmatter structure:
```yml
---
title: "Your Post Title"
description: "A brief description of your post!"
date: 2026-01-01
authors:
- enscribe
image: ./assets/banner.png
tags:
- tag1
- tag2
---
```
The blog post schema is defined as follows:
| Field | Type (Zod) | Requirements | Required |
| ------------- | ------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -------- |
| `title` | `string` | Should be ≤60 characters. | Yes |
| `description` | `string` | Should be ≤155 characters. | Yes |
| `date` | `coerce.date()` | Must be in `YYYY-MM-DD` format. | Yes |
| `order` | `number` | Sort order for subposts within a series. Defaults to `0` if not provided. | Optional |
| `tags` | `string[]` | Preferably use kebab-case for these. | Optional |
| `authors` | `reference("authors")[]` | Each entry must match the id of a file in `src/content/authors/` (e.g. if their file is named `jane-doe.md`, use `jane-doe` in the array). Validated at build time. | Yes |
| `image` | `image()` | Should be exactly 1200px × 630px. | Optional |
| `draft` | `boolean` | Defaults to `false` if not provided. You can also prefix a filename with `_` to hide it from the content loader entirely. | Optional |
### Subposts
A post becomes a series by nesting sibling Markdown files next to its `index.md`:
```
src/content/blog/
├── a-standalone-post.md
└── my-series/
├── index.md
├── getting-started.md
└── going-further.md
```
The entire series renders as one continuous document, with the address bar syncing as you scroll between parts. Every subpost still gets its own URL (`/blog/my-series/getting-started`). Use the `order` frontmatter field to control the sequence. Only one level of nesting is supported, so files nested any deeper are ignored.
### Markdown extensions
A few authoring features exist that extend beyond standard Markdown:
- Callouts use the [directive](https://talk.commonmark.org/t/generic-directives-plugins-syntax/444) syntax, with five variants (`note`, `tip`, `warning`, `caution`, `important`) rendered as collapsible `<details>` elements. Append `{closed}` to start one collapsed:
```markdown
:::note[An optional custom title]
Hello, world!
:::
```
- Math is written as `$inline$` or `$$display$$` $\LaTeX$ and rendered to MathML at build time.
- Inline code ending in an annotation gets syntax highlighting: `` `const x = 1{:ts}` `` highlights as TypeScript, and `` `text{:.string}` `` paints with the theme's color for a [TextMate scope](https://macromates.com/manual/en/language_grammars).
### Authors
Add author information in `src/content/authors/` as Markdown files. A file named `[author-name].md` can be associated with a blog post if `"author-name"` (the id) is added to the `authors` field:
```yml
---
name: "enscribe"
pronouns: "he/him"
avatar: "https://avatars.githubusercontent.com/u/71956291?v=4"
bio: "d(-_-)b"
mail: "[email protected]"
socials:
website: "https://enscribe.dev"
twitter: "https://twitter.com/enscrbe"
github: "https://github.com/jktrn"
---
```
The author schema is defined as follows:
| Field | Type (Zod) | Requirements | Required |
| ---------- | ------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -------- |
| `name` | `string` | n/a | Yes |
| `pronouns` | `string` | n/a | Optional |
| `avatar` | `url()` or `string.startsWith("/")` | Should be either a valid URL or a path starting with `/`. | Yes |
| `bio` | `string` | n/a | Optional |
| `mail` | `email()` | Must be a valid email address. | Optional |
| `socials` | `record(string, url())` | A map of any label you like to a valid URL. Each label is matched to an icon in `src/components/SocialIcons.astro`. | Optional |
### Projects
Add projects in `src/content/projects/` as Markdown files:
```yml
---
name: "Project A"
description: "This is an example project description! You should replace this with a description of your own project."
tags: ["Framework A", "Library B", "Tool C", "Resource D"]
image: "./placeholder.png"
link: "https://example.com"
startDate: "2024-01-01"
endDate: "2024-02-01"
---
```
The project schema is defined as follows:
| Field | Type (Zod) | Requirements | Required |
| ------------- | --------------- | --------------------------------------- | -------- |
| `name` | `string` | n/a | Yes |
| `description` | `string` | n/a | Yes |
| `link` | `url()` | Must be a valid URL. | Yes |
| `tags` | `string[]` | n/a | Optional |
| `image` | `image()` | Should be exactly 1200px × 630px. | Optional |
| `startDate` | `coerce.date()` | Must be in `YYYY-MM-DD` format. | Optional |
| `endDate` | `coerce.date()` | Must be in `YYYY-MM-DD` format. | Optional |
## License
This project is open source and available under the [MIT License](LICENSE).
---
### Star history
<a href="https://star-history.com/#jktrn/astro-erudite&Date">
<picture>
<source media="(prefers-color-scheme: dark)" srcset="https://api.star-history.com/svg?repos=jktrn/astro-erudite&type=Date&theme=dark" />
<source media="(prefers-color-scheme: light)" srcset="https://api.star-history.com/svg?repos=jktrn/astro-erudite&type=Date" />
<img alt="Star History Chart" src="https://api.star-history.com/svg?repos=jktrn/astro-erudite&type=Date" />
</picture>
</a>
---
Built with ♥ by [enscribe](https://enscribe.dev)!
[Stargazers]: https://img.shields.io/github/stars/jktrn/astro-erudite?color=fafafa&logo=github&logoColor=fff&style=flat
[Astro Version]: https://img.shields.io/github/package-json/dependency-version/jktrn/astro-erudite/astro?color=0a0a0a&logo=astro&logoColor=fff&style=flat
[Dependencies]: https://img.shields.io/badge/dependencies-15-fafafa?style=flat
[License]: https://img.shields.io/github/license/jktrn/astro-erudite?color=0a0a0a&logo=github&logoColor=fff&style=flat
看看同类模板
对比同技术栈与用途的模板,找到更适合的视觉与内容结构。

astrowind
⭕️ AstroWind: A free template using Astro v7 and Tailwind CSS v4. Astro starter theme.
Astro · 博客

astro-paper
A minimal, accessible and SEO-friendly Astro blog theme.
Astro · 博客

fuwari
✨A static blog template built with Astro.
Astro · 博客

Firefly
Firefly 是一款基于 Astro 的静态博客主题,由 CuteLeaf 在 saicaca 的 Fuwari 模板基础上二次开发,主打清新美观的视觉风格。
Astro · 博客

astro-theme-cactus
A simple Astro theme. Use it to create your blog or website.
Astro · 作品集

astrofy
Astrofy is a free and open-source template for your Personal Portfolio Website built with Astro and TailwindCS…
Astro · 作品集
