Next Generation Static Blog Framework ,下一代静态博客框架(支持页面/配置热重载)
- English | 简体中文
- English Docs | 中文文档 | Docs for Beta
- Demo: with valaxy-theme-yun
Usage
Try it Online
Init Project Locally
Just run the following command to init your blog:
# pnpm (recommended)
pnpm create valaxy
# npm
# npm init valaxy
# yarn
# yarn create valaxy
For a example, you can see demo/yun folder.
Features
- ⚡️ Vue 3, Vite 4, pnpm, ESBuild - born with fastness
- 🔥 Hot Reload with Config & Markdown
- 🔧 Type Tooltip for all config by
valaxy.config.ts
- 🗒 Extended Markdown Frontmatter
- 🗂 File based routing via vite-plugin-pages
- 📦 Components auto importing via unplugin-vue-components
- 🖨 Static-site generation (SSG) via vite-ssg (SPA is OK!)
- 🕸 RSS & Sitemap
- 🎨 Free to use Tailwind CSS via UnoCSS
- 🌍 CSS i18n in One Page
- 🔍 Use icons from any icon sets with classes - Icônes
- 👔 Extended Theme with Layout system
- ⚙️ Unit Testing with Vitest
- ☁️ Deploy zero-config
- Netlify with
netlify.toml
- GitHub Pages with
.github/workflows/gh-pages.yml
GitHub Actions
- Netlify with
- ♻️ Use any vite plugins
- 📲 You can implement PWA by vite-plugin-pwa
- ...
Dev
Want to get involved in the development? Look here.
Want to create your theme? Check valaxy-theme-starter.
Thanks
💗 The implementation of Valaxy is based on or refer the following projects:
from https://github.com/YunYouJun/valaxy
(demo blog: https://big-cake-jpg.github.io/
its source code: https://github.com/Big-Cake-jpg/big-cake-jpg.github.io)
-------------------------------------------------
Valaxy —— 快到没边的全新静态博客程序
打开了 Valaxy 的文档开始一顿操作,设置好以后已经基本处于可以用在生产环境的情况了。
同时我也感受到了它超快的速度以及原生的页面热重载,便打算把它介绍给大家。
Vue 3, Vite 2, pnpm, ESBuild - born with fastness
项目地址:https://github.com/YunYouJun/valaxy
本地初始化
新建一个文件夹,然后在这个文件夹内打开终端,输入如下内容进行初始化:
npm init valaxy
# `pnpm create valaxy` is recommened by author
根据命令行提示即可完成项目初始化。默认使用 Yun 主题,也可以选择文档主题(theme-press)。
进入到生成的项目文件夹内,输入指令安装依赖并启动本地预览:
npm install
# yarn
npm run dev
# yarn dev
本地预览启动以后,可以访问 http://localhost:4859 查看效果。然后就可以修改 valaxy.config.ts 来自定义你的博客了。
自动构建
可以使用 GitHub Pages/Netlify/Vercel/Cloudflare Pages。
.github/workflows/gh-pages.yml 将会自动部署 GitHub Pages,其他请参考文档。
手动部署
输入如下指令生成静态文件,然后就可以把 dist 文件夹下的内容部署到自己的服务器上了:
npm run build
# npm run build:spa for SPA
注意事项
Valaxy 目前还处于早期开发阶段,Yun 主题的功能仅复刻了 Hexo 版本的主要功能,你可以通过反馈 Bug/捐助云游君来支持 Valaxy 的开发。
No comments:
Post a Comment