笔记放入 src/content/wiki/ 后自动生成 URL 与侧边栏导航,无需在配置文件中登记路由
veka — Astro 启动器模板
作者 masmuss
Veka 是一个基于 Astro 的个人 Wiki 与数字花园启动模板,把 Markdown 笔记放入内容目录即可自动生成带侧边栏的页面与本地静态搜索。
看看你的网站会是什么样
浏览真实页面截图,比较内容排版与手机效果。点击下方缩略图切换,放大查看整页细节。
全部页面与视图 3
截图用于了解视觉与布局,交互效果请以实际项目为准。
值得关注的模板亮点
从已有项目资料中,快速了解它的特点。
使用 Pagefind 在构建阶段生成本地静态搜索索引,不依赖第三方搜索服务
frontmatter 由 Zod 校验,缺少标题或日期格式错误会在构建时被拦截
提供 growthStage 字段,可用 seedling、budding、evergreen 标记笔记成熟度
内置 SEO 处理,包括标题与描述规范化、Open Graph、Twitter Card、canonical URL 和 JSON-LD
WikiLayout 采用导航、正文、目录三栏网格布局
模板详细介绍
Veka 是面向 Astro 的个人 Wiki 和数字花园启动模板,定位是轻量的笔记发布工具,而不是完整文档框架。笔记文件放在 src/content/wiki/ 目录下,可以自由创建多层子目录,路由和侧边栏导航会按目录结构自动生成,不需要在配置文件里登记页面。每篇笔记使用 Markdown 或 MDX,frontmatter 由 Zod 校验,必须包含 title、description、createdAt、updatedAt、tags、isPinned 和 growthStage 字段。growthStage 取 seedling、budding 或 evergreen,用来标记笔记的成熟度。
搜索使用 Pagefind,在构建阶段生成本地索引,不依赖第三方搜索服务。由于索引来自静态构建产物,本地开发模式下无法直接测试搜索,需要先执行构建再预览。站点身份、规范链接、Open Graph、Twitter Card 和 JSON-LD 等 SEO 信息集中在 src/lib/site-config.ts 中配置,页面级标题和描述会按规则做长度规范化。
模板默认输出静态站点,可部署到 Vercel、Netlify 或 Cloudflare Pages,构建命令为 pnpm run build,该命令会同时触发 Astro 构建和 Pagefind 索引生成。仓库采用 MIT 许可,可免费使用、修改和分发代码;但演示中的图片、字体、图标等第三方素材需要单独核对许可,域名、托管等外部服务也可能产生费用。
适合你的项目吗?
适用场景
- 搭建个人数字花园,按主题目录整理并逐步完善笔记
- 建立内部或个人 Wiki,用 Markdown 记录概念、想法与参考资料
- 为已有 Astro 项目补充一套轻量的笔记发布与本地搜索方案
- 部署到 Vercel、Netlify 或 Cloudflare Pages 等静态托管平台
适合人群
- 习惯用 Markdown 写作、希望减少路由配置的笔记作者
- 需要本地静态搜索、不想接入第三方搜索服务的个人站点
- 想用目录结构组织多层级笔记内容的 Astro 用户
- 接受 frontmatter 字段校验、愿意按模板约定填写元数据的开发者
上手与定制指南
结合仓库当前版本的说明,按下面的资料检查内容、配置与运行要求。
- 1
可用 pnpm dlx degit masmuss/veka my-wiki 获取模板,然后执行 pnpm install 与 pnpm run dev
- 2
笔记放在 src/content/wiki/ 目录,支持 .md 和 .mdx,frontmatter 必须包含 title、description、createdAt、updatedAt、tags、isPinned、growthStage
- 3
本地开发模式无法测试 Pagefind 搜索,需先运行 pnpm run build 再执行 pnpm run preview
- 4
站点名称、URL、OG 图片、favicon 等在 src/lib/site-config.ts 中修改
- 5
部署到静态托管平台时,构建命令设置为 pnpm run build,以同时生成页面和搜索索引
授权与来源资料
使用条件与限制
免费使用 · 保留许可声明本次收录的是公开仓库中采用 MIT 许可的免费版本;免费范围为该版本代码,不代表外部服务或第三方素材免费。
使用时需要遵守
- 允许免费使用、修改、商用和分发该版本代码。
- 分发代码副本或实质性部分时,保留原作者版权声明和完整 MIT 许可声明。
- 代码按现状提供;担保与责任限制以原许可证及适用法律为准。
额外费用与待核对事项
- 本地开发模式无法直接测试 Pagefind 搜索,必须先执行构建再预览,因为搜索索引来自静态构建产物。
- 部署到托管平台时需将构建命令设为 pnpm run build,以同时触发 Astro 构建和 Pagefind 索引生成。
- 演示图片、字体、图标及其他第三方素材需按各自许可核对,不能仅凭代码的 MIT 许可判断。
- 域名、托管、数据库、支付或 AI 等外部服务可能另外收费。
查看原文依据
Permission is hereby granted, free of charge
许可证原文
Pagefind search works by reading the static build output. To test search locally, you must run npm run build followed by npm run preview.
README 原文
https://github.com/masmuss/veka/blob/main/LICENSEhttps://github.com/masmuss/veka/blob/main/README.mdMake sure your build command on the target platform is set to: `pnpm run build`
README 原文
DeepSeek 根据仓库许可证和 README 整理 ·2026-10-02。结果仅覆盖已读取资料,依赖、图片、字体及后续条款变更以各自原文为准。
项目核对记录与介绍依据
模板资料
- 来源平台
- Astro Themes
- 资料与维护参考分
- 资料较完整 · 87 / 100
- 技术栈
- Astro
- 网站类型
- 启动器
这个分数如何计算
本站按许可资料(最高30分)、演示链接(12分)、预览图(10分)、Star数(15分)、记录的维护时间(15分)、描述完整度(8分)、功能记录(5分)和分类资料(5分)计算。它不是代码、安全或性能测试,也不是 Google 评分;有链接不代表已实测可用。
这个项目需要核对什么
- 记录的仓库更新时间
- 2026-07-24
- 截图检查日期
- 2026-10-02
已收录演示链接。请用你的内容与屏幕尺寸检查;有演示不代表表单、认证或支付已经可用。
目录记录的主要技术栈是 Astro。请通过依赖清单和锁文件核对实际版本与托管要求。这些说明基于收录资料,不代表代码审计或部署实测。
查看具体选型方法 →介绍的制作与核对状态
介绍由 AI 辅助整理目录与仓库资料。仓库作者不等于这篇介绍的审核者。
已完成服务器许可规则与 AI 来源核对;未经过人工编辑审核。
查看当时使用的来源资料
SHA-256: b7a0fd9deda49277e21c31877cf85d7fbc6836821fb75667d727196cefae4070
2026-10-02T20:19:06.636Z
来源文件 / 仓库# 🌲 Veka
**The Minimalist Digital Garden & Wiki Starter for Astro.**
Veka is not a competitor to massive documentation frameworks. It is the antithesis. Built specifically for those who want a fast, organic place to take notes — a digital garden or personal wiki — free from rigid routing configuration.
Drop your Markdown files into the folder, and let the system weave them together automatically.






Production demo available at [demo-veka.khoirul.me](https://demo-veka.khoirul.me) or [wiki.khoirul.me](https://wiki.khoirul.me)
---
## ⚡ Why Veka?
- **Zero-Config Routing:** No need to register navigation in a config file. Create folders as deep as you like (e.g. `src/content/wiki/koding/arsitektur/`), and URLs with sidebar navigation are generated automatically.
- **Ultra-Fast Static Search:** Powered by [Pagefind](https://pagefind.app/). Search is indexed locally during the build process — no third-party services required.
- **Zod Schema Validation:** Frontmatter is strictly validated. No more build errors from a missing title or incorrectly formatted date.
- **"Digital Garden" Concept:** Comes with a `growthStage` property (`seedling`, `budding`, `evergreen`) to track the maturity level of each note.
- **100% Lighthouse Score:** The UI is built selectively using minimal components and vanilla JS for interactivity, ensuring zero runtime bloat.
---
## 🚀 Quick Start (Under 1 Minute)
Run these commands in your terminal to clone the template and start a local server:
```bash
# 1. Clone this repository (or use degit)
pnpm dlx degit masmuss/veka my-wiki
# 2. Enter the directory
cd my-wiki
# 3. Install dependencies
pnpm install
# 4. Start the local server
pnpm run dev
```
Important Note for Search Features: Pagefind search works by reading the static build output. To test search locally, you must run npm run build followed by npm run preview.
## 📝 How to Write Notes
All your notes live in the `src/content/wiki/` directory. Feel free to create new sub-directories. Every `.md` or `.mdx` file must include the following frontmatter:
```plaintext
---
title: "Your Note Title"
description: "Brief description for SEO and search snippets."
createdAt: 2026-07-05
updatedAt: 2026-07-05
tags: ["concept", "idea"]
isPinned: false
growthStage: "seedling" # Options: seedling | budding | evergreen
---
Write your thoughts here using Markdown...
```
## 🏗️ Project Structure
```plaintext
├── src/
│ ├── components/
│ │ ├── seo/ # Seo.astro, JsonLd.astro
│ │ └── shell/ # BaseHead.astro, Header.astro
│ ├── content/
│ │ ├── config.ts # Zod schema validation
│ │ └── wiki/ # Your markdown files and folders
│ ├── layouts/
│ │ ├── BaseLayout.astro # HTML shell, delegates head to BaseHead
│ │ └── WikiLayout.astro # 3-Column Grid (Nav, Content, TOC)
│ ├── lib/
│ │ ├── seo.ts # Title/description normalization & canonical URL
│ │ └── site-config.ts # Site-wide configuration (name, URL, OG image, etc.)
│ └── pages/
│ ├── index.astro # Dashboard / Home
│ └── wiki/
│ └── [...slug].astro # Dynamic routing engine
└── astro.config.mjs
```
## ⚙️ Configuration
Edit `src/lib/site-config.ts` to customize your site identity. All fields are used for SEO meta tags, Open Graph, and JSON-LD structured data.
```ts
export const SITE = {
name: "Veka", // Site name (used in <title> suffix & og:site_name)
title: "Veka", // Default page title
description: "Minimalist Digital Garden", // Fallback meta description
author: "Veka", // JSON-LD author
url: "https://veka-9tg.pages.dev", // Canonical base URL
image: "/og-image.png", // Default Open Graph image
favicon: "/favicon.svg", // Favicon path
};
```
SEO features (auto-generated per page):
- `<title>` normalization — appends `" | Veka"` if not present, truncates at 60 chars
- Description normalization — enforces 120–160 character range
- Open Graph tags (`og:title`, `og:description`, `og:image`, `og:type`, `og:url`, `og:site_name`)
- Twitter Card tags (`twitter:card`, `twitter:title`, `twitter:description`, `twitter:image`)
- Canonical URL — strips hash and trailing slash
- JSON-LD structured data — `WebSite` for all pages, `Article` for wiki notes (with `datePublished`, `dateModified`, `keywords`)
- Article metadata — `article:published_time`, `article:modified_time`, `article:tag` for wiki pages
## 🌍 Deployment
Veka is configured as a Static Site Generator (SSG) by default. Deployment is seamless on platforms like Vercel, Netlify, or Cloudflare Pages.
Make sure your build command on the target platform is set to: `pnpm run build`
This command will automatically run `astro build` and trigger the pagefind integration to build the search index.
看看同类模板
对比同技术栈与用途的模板,找到更适合的视觉与内容结构。

astrowind
⭕️ AstroWind: A free template using Astro v7 and Tailwind CSS v4. Astro starter theme.
Astro · 博客
accessible-astro-starter
Accessible Astro Starter 是一个以无障碍为核心理念的 Astro 6 启动模板,由 incluud 团队维护。
Astro · 博客

astro-erudite
An opinionated, unstyled static blogging template built with Astro and native CSS.
Astro · 作品集

astro-shopify
astro-shopify 是一个面向开发者的轻量级电商启动模板,用于构建基于 Shopify 的无头店面。
Astro · 电商

brutal
A neobrutalism Astro starter theme
Astro · 启动器

qwind
⭕️ Qwind: A template to make your website using Qwik + Tailwind CSS.
Astro · 工具站
