3 releases
Uses new Rust 2024
| 0.1.3 | Jan 15, 2026 |
|---|---|
| 0.1.2 | Jan 14, 2026 |
| 0.1.0 | Jan 14, 2026 |
#1821 in Command line utilities
285KB
6.5K
SLoC
Typstify
A high-performance static site generator with Typst and Markdown support.
Features
- 🚀 Blazing Fast - Built in Rust for maximum performance
- 📝 Dual Format - Write in Markdown or Typst
- 🔍 Built-in Search - Tantivy powered full-text search with WASM runtime
- 🌐 Multi-language - First-class i18n support
- 🔄 Live Reload - Instant feedback during development
- 📊 Syntax Highlighting - 100+ languages supported
- 📰 RSS & Sitemap - Automatic feed generation
- 🎨 Customizable - Templates, themes, and styles
Crates
Typstify is a modular project composed of several crates:
Installation
From Cargo
cargo install typstify
From Source
git clone https://github.com/longcipher/typstify
cd typstify
cargo install --path bin/typstify
Quick Start
1. Create a New Site
mkdir my-site && cd my-site
2. Create Configuration
Create config.toml:
[site]
title = "My Blog"
base_url = "https://example.com"
[build]
output_dir = "public"
3. Create Content
mkdir -p content/posts
typstify new posts/hello-world
4. Build & Preview
typstify watch --open
Your site is now running at http://127.0.0.1:3000!
Commands
| Command | Description |
|---|---|
typstify build |
Build the site for production |
typstify watch |
Start dev server with live reload |
typstify new <path> |
Create new content from template |
typstify check |
Validate configuration and content |
Build Options
typstify build --output dist # Custom output directory
typstify build --drafts # Include draft posts
Watch Options
typstify watch --port 8080 # Custom port
typstify watch --open # Open browser automatically
Global Options
typstify -c site.toml build # Custom config file
typstify -v build # Verbose output
typstify -vvv build # Debug output
Project Structure
my-site/
├── config.toml # Site configuration
├── content/ # Content files
│ ├── posts/ # Blog posts (Markdown/Typst)
│ ├── docs/ # Documentation
│ └── about.md # Static page
├── templates/ # HTML templates (optional)
├── style/ # CSS/Tailwind (optional)
├── assets/ # Static assets
└── public/ # Generated output
Content Formats
Markdown
---
title: "My Post"
date: 2024-01-15
tags: ["rust", "web"]
---
# Hello World
Your content here...
Typst
// typstify:frontmatter
// title: "Technical Doc"
// date: 2024-01-15
= Introduction
Your Typst content here...
Configuration Reference
See docs/configuration.md for full configuration options.
Basic Configuration
[site]
title = "My Site"
description = "Site description"
base_url = "https://example.com"
default_language = "en"
languages = ["en", "zh"]
[build]
output_dir = "public"
minify = false
syntax_theme = "base16-ocean.dark"
drafts = false
[search]
enabled = true
index_fields = ["title", "body", "tags"]
[rss]
enabled = true
limit = 20
Documentation
Architecture
Typstify is organized as a Cargo workspace:
| Crate | Description |
|---|---|
typstify |
CLI binary |
typstify-core |
Configuration and content types |
typstify-parser |
Markdown/Typst parsing |
typstify-generator |
HTML generation and build |
typstify-search |
Search indexing (Tantivy) |
typstify-search-wasm |
WASM search runtime |
typstify-ui |
Leptos UI components |
Development
Prerequisites
- Rust 1.75+
- Bun (for CSS/JS tooling)
- wasm-pack (for WASM builds)
Setup
git clone https://github.com/longcipher/typstify
cd typstify
just dev
Commands
just format # Format code
just lint # Run linters
just test # Run all tests
just build # Production build
License
Apache License 2.0 - see LICENSE for details.
Contributing
Contributions are welcome! Please read our Contributing Guide before submitting a PR.
Dependencies
~45–63MB
~1M SLoC