终端风格极简设计,从 hugo-theme-console 移植到 Astro
astro-theme-console — Astro 博客模板
作者 thaske
astro-theme-console 是一个面向开发者的 Astro 博客主题,采用终端风格设计,提供面包屑导航、响应式布局与 MDX 支持,由 hugo-theme-console 移植而来。
看看你的网站会是什么样
浏览真实页面截图,比较内容排版与手机效果。点击下方缩略图切换,放大查看整页细节。
目前有 1 张原始预览,可打开完整图片查看设计细节。
截图用于了解视觉与布局,交互效果请以实际项目为准。
值得关注的模板亮点
从已有项目资料中,快速了解它的特点。
以 Astro 组件形式提供 Layout、Header、Footer、PostListItem 等,共享元数据集中在 src/consts.ts
博客文章放在 src/content/blog/,支持 .md 与 .mdx,frontmatter 含 title、description、pubDate、tags、draft
内置面包屑导航、响应式布局与带日期的文章列表
SEO 元标签与 Shiki 语法高亮
可选 Google Analytics,通过向 Layout 传入 analyticsId 启用
模板详细介绍
astro-theme-console 是 thaske 维护的 Astro 博客主题,README 描述其为「面向开发者的极简终端风格主题」,并注明从 hugo-theme-console 移植而来。主题以组件形式提供,包含 Layout、Header、Footer、PostListItem 等 Astro 组件,站点标题、描述与分析 ID 等共享元数据集中放在 src/consts.ts 中。
内容组织上,主题约定博客文章位于 src/content/blog/ 目录,支持 .md 与 .mdx 文件,每篇文章通过 frontmatter 提供 title、description、pubDate、tags、draft 字段。功能方面 README 列出:终端风格设计、面包屑导航、响应式布局、带日期的文章列表、MDX 支持、SEO 元标签、Shiki 语法高亮,以及可选的 Google Analytics(通过向 Layout 传入 analyticsId 启用)。仓库内 example 目录提供了完整可运行的示例站点。
使用限制方面,主题通过 bun add github:thaske/astro-theme-console 从 GitHub 仓库安装,README 未提供 npm 包名或版本发布信息;仓库 stars 为 0,资料中也没有关于维护活跃度、浏览器兼容范围或无障碍支持的说明。许可为 MIT,允许免费使用、修改、商用与分发,但演示图片、字体、图标等第三方素材需按各自许可单独核对,域名、托管等外部服务可能另行收费。
适合你的项目吗?
适用场景
- 搭建个人开发者博客,文章以 Markdown 或 MDX 撰写
- 希望站点呈现终端/控制台视觉风格,而非常规杂志式排版
- 需要文章列表展示日期与标签,并带面包屑导航
- 在 Astro 项目中直接引用主题组件,自行组织页面结构
- 参考仓库 example 目录快速了解主题的完整用法
适合人群
- 使用 Astro 并熟悉组件化开发的开发者
- 偏好极简、终端风格界面的个人博客作者
- 以 Markdown/MDX 写作并需要语法高亮的技术内容创作者
- 希望以 MIT 许可自由修改和分发主题代码的用户
上手与定制指南
结合仓库当前版本的说明,按下面的资料检查内容、配置与运行要求。
- 1
通过 bun add github:thaske/astro-theme-console 从 GitHub 仓库安装,README 未提供 npm 包名
- 2
文章需放在 src/content/blog/ 目录,frontmatter 使用 title、description、pubDate、tags、draft 字段
- 3
站点标题、描述与分析 ID 等共享元数据建议集中写在 src/consts.ts 中
- 4
启用 Google Analytics 需向 Layout 组件传入 analyticsId
- 5
仓库 example 目录提供完整可运行的示例站点,可作为配置参考
授权与来源资料
使用条件与限制
免费使用 · 保留许可声明本次收录的是公开仓库中采用 MIT 许可的免费版本;免费范围为该版本代码,不代表外部服务或第三方素材免费。
使用时需要遵守
- 允许免费使用、修改、商用和分发该版本代码。
- 分发代码副本或实质性部分时,保留原作者版权声明和完整 MIT 许可声明。
- 代码按现状提供;担保与责任限制以原许可证及适用法律为准。
额外费用与待核对事项
- Google Analytics 为可选功能,启用需向 Layout 传入 analyticsId,并依赖 Google 的外部服务与账号。
- README 仅提供从 GitHub 仓库安装的方式,未提供 npm 包名或版本发布信息。
- 演示图片、字体、图标及其他第三方素材需按各自许可核对,不能仅凭代码的 MIT 许可判断。
- 域名、托管、数据库、支付或 AI 等外部服务可能另外收费。
查看原文依据
Permission is hereby granted, free of charge
许可证原文
Google Analytics support (optional)
README 原文
https://github.com/thaske/astro-theme-console/blob/master/LICENSEhttps://github.com/thaske/astro-theme-console/blob/master/README.mdbun add github:thaske/astro-theme-console
README 原文
DeepSeek 根据仓库许可证和 README 整理 ·2026-10-04。结果仅覆盖已读取资料,依赖、图片、字体及后续条款变更以各自原文为准。
项目核对记录与介绍依据
模板资料
- 来源平台
- GitHub
- 资料与维护参考分
- 资料一般 · 68 / 100
- 技术栈
- Astro
- 网站类型
- 博客
这个分数如何计算
本站按许可资料(最高30分)、演示链接(12分)、预览图(10分)、Star数(15分)、记录的维护时间(15分)、描述完整度(8分)、功能记录(5分)和分类资料(5分)计算。它不是代码、安全或性能测试,也不是 Google 评分;有链接不代表已实测可用。
这个项目需要核对什么
- 记录的仓库更新时间
- 2025-10-16
- 截图检查日期
- 2026-10-04
目前没有记录演示链接。请依据仓库说明在本地评估;仅凭截图无法确认交互行为。
目录记录的主要技术栈是 Astro。请通过依赖清单和锁文件核对实际版本与托管要求。这些说明基于收录资料,不代表代码审计或部署实测。
查看具体选型方法 →介绍的制作与核对状态
介绍由 AI 辅助整理目录与仓库资料。仓库作者不等于这篇介绍的审核者。
审核声明: [email protected] · 2026-10-04
查看当时使用的来源资料
SHA-256: 18250d60e07fbd6d502f17a9cd1ffba377222954519e98013ad5257d02264de4
2026-10-04T00:26:20.628Z
来源文件 / 仓库# Astro Theme Console
A minimal, terminal-style theme for Astro. Features a clean, console-inspired design with breadcrumb navigation and responsive layout. Ported from [hugo-theme-console](https://github.com/mrmierzejewski/hugo-theme-console).
## Features
- Terminal-inspired design
- Breadcrumb navigation
- Responsive layout
- Blog post listing with dates
- MDX support
- SEO-friendly meta tags
- Syntax highlighting with Shiki
- Google Analytics support (optional)
## Screenshots
<div style="display: flex; flex-direction: column; gap: 1rem;">
<img src="images/home.png" alt="Home Screenshot" width="500" />
<img src="images/about.png" alt="About Screenshot" width="500" />
<img src="images/posts.png" alt="Posts Screenshot" width="500" />
<img src="images/post.png" alt="Post Screenshot" width="500" />
</div>
## Installation
```bash
bun add github:thaske/astro-theme-console
```
## Usage
### Using Components
Import components directly from the theme, and centralize shared metadata in a `src/consts.ts` file (just like the example project):
```astro
---
import Layout from "@thaske/astro-theme-console/layouts/Layout.astro";
import Header from "@thaske/astro-theme-console/components/Header.astro";
import Footer from "@thaske/astro-theme-console/components/Footer.astro";
import PostListItem from "@thaske/astro-theme-console/components/PostListItem.astro";
import { ANALYTICS_ID, SITE_DESCRIPTION, SITE_TITLE } from "../consts";
---
<Layout
title={SITE_TITLE}
description={SITE_DESCRIPTION}
analyticsId={ANALYTICS_ID}
>
<h1>Hello World</h1>
</Layout>
```
Example `src/consts.ts`:
```ts
export const SITE_TITLE = "mysite";
export const SITE_DESCRIPTION = "A minimal, terminal-style blog";
export const ANALYTICS_ID = "G-XXXXXXXXXX";
```
### Configuration
The theme expects the following structure for blog posts:
```
src/
content/
blog/
post-1.md
post-2.mdx
```
Each blog post should have frontmatter like:
```yaml
---
title: "Post Title"
description: "Post description"
pubDate: 2024-01-01
tags: ["tag1", "tag2"]
draft: false
---
```
### Google Analytics
To enable Google Analytics, pass your tracking ID to the Layout component:
```astro
<Layout analyticsId="G-XXXXXXXXXX">
<!-- content -->
</Layout>
```
## Example Site
See the `example` directory for a complete working example.
## License
MIT
看看同类模板
对比同技术栈与用途的模板,找到更适合的视觉与内容结构。

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 · 作品集
