100% open source MIT licensed PHP 8.4+

Static sites,
quietly crafted.

Documentation out of the box, but Leaf is a full static site generator under the hood. Ship landing pages, marketing, blogs, anything. Themes, search, multi-locale, SEO baked in.

$ composer create-project zephyrus-framework/leaf my-docs
Leaf documentation preview Leaf documentation preview
1cmd
to build the whole site
0config
required to get running
58tests
covering the core library
hosts
deploy static HTML anywhere
Features

Everything you need.
Nothing you don't.

Leaf handles the build pipeline, SEO, search, and theming so you can focus on content.

00 · Positioning

Documentation out of the box.
Anything static, under the hood.

The default scaffold gets you polished documentation in minutes. That's the fast path. But Leaf is a full static site generator underneath. Ship a landing page, a marketing site, a blog, and drop into a PHP controller when a page needs more. One pipeline. One deploy.

Docs out of the box Landing pages Marketing sites Blogs Custom PHP
01

One-command builds

Run composer build and get a fully static site in dist/. Ready for Netlify, Vercel, GitHub Pages, or any web server.

02

Markdown content

Front matter, GFM tables, fenced code blocks. Syntax highlighting via Prism.js with automatic copy buttons on every block.

03

Multi-locale, out of the box

Default locale at root, others in subdirectories. Automatic hreflang tags and sitemap alternates. No plugin gymnastics.

04

Client-side full-text search

Fuzzy search across every page with zero backend. ⌘K to open, arrow keys to navigate, instant results.

05

SEO & structured metadata

Automatic sitemap.xml, robots.txt, canonical URLs, OpenGraph tags. Everything crawlers expect, nothing you have to remember.

06

Light & dark themes

Both themes polished and production-ready. Respects system preference, with a manual toggle and smooth transitions across every component.

Build pipeline

Ten lines of PHP.
A production build.

The default bin/build.php is a single file you own. Add routes, hook into the pipeline, post-process output. It's yours to evolve.

  • Composable Add paths, extend the kernel, register routes.
  • Hookable Pre-build and post-build callbacks for custom steps.
  • Transparent No black boxes. The whole build is regular PHP you can read.
bin/build.php
$app = new Application();
$command = new BuildCommand($app);

// Add blog posts as build paths
$command->addPaths(['/blog', '/blog/my-post']);

// Custom post-build step
$command->onPostBuild(function ($result, $outputDir) {
    echo "Built {$result->pagesBuilt} pages!" . PHP_EOL;
});

exit($command->run());
Quick start

Up and running
in thirty seconds.

  1. Create your project

    Scaffold a new Leaf site with Composer. Everything wires up on first run.

    composer create-project zephyrus-framework/leaf my-docs
  2. Write your content

    Drop Markdown files under content/. Front matter controls titles, order, and metadata.

    ---
    title: Introduction
    order: 1
    ---
    # Welcome to my docs
    Your documentation starts here.
  3. Build & deploy

    Render every page to static HTML in dist/. Push anywhere: Netlify, Vercel, GitHub Pages, or your own server.

    composer build
    # dist/ is ready to deploy anywhere

Standing on the shoulders of

  • PHP 8.4
  • Zephyrus
  • CommonMark
  • Prism.js
  • Latte 3
  • Composer

Start writing. Stop configuring.

Open source, MIT licensed, and built to be read. Ship your docs this afternoon.