Installation

Introduction

ReeWeb has one prerequisite - Bun. The CLI is the runtime, package manager, bundler, and test runner all in one. The install task fetches the other tooling it needs.

Installing Bun

macOS / Linux / WSL
curl -fsSL https://bun.sh/install | bash
Windows
powershell -c "irm bun.sh/install.ps1|iex"

Verify the install:

bun --version

The output should be a version number. If command fails, the installer's directory isn't on your PATH.

Starting a Project

ReeWeb is a free download. Pick a name for your project folder, create it, download the tagged .tar.gz archive into it, unpack it, install, and start developing. Set the name once below and every command on this page updates, so you can copy-paste them as-is:

mkdir __PROJECT_DIR__
cd __PROJECT_DIR__
curl -O https://reepolee.com/downloads/reeweb.tar.gz
tar -xzf reeweb.tar.gz
bun reeweb:install
bun dev

bun reeweb:install creates .env when needed, initialises Git, installs Bun dependencies, installs the conc development runner, and fetches ReeWeb's formatter and vendor assets. It does not build CSS or prepare images; bun dev and bun ssg do that when they run.

The install task pulls Tailwind CSS v4, tailwind-merge, and Bun's type definitions (@types/bun) as dev dependencies. ReeWeb has zero runtime dependencies. The archive ships without Git history, so your copy is yours from the first commit. See the Upgrade Guide for adopting changes from a later release.

Generating the Static Site

bun ssg

This runs the static site generator (scripts/ssg.ts), which:

  • Renders all .ree templates and .md files to static HTML
  • Copies static assets (CSS, JS, images, fonts) to the output directory
  • Generates localized routes for every configured language
  • Emits redirects for paths declared in config/redirects.ts

The output goes to dist/. Serve it with any static file server:

bun preview

This starts a lightweight HTTP server on localhost:3000 serving the generated files.

Development Mode

The bun dev command above uses conc (concurrently) to start image preparation, the Tailwind CSS watcher (bun css:watch), and the development server (bun development) in parallel. Changes to templates, markdown, translations, or CSS are detected automatically and the browser reloads. No manual refresh needed.

The CSS watcher recompiles src/css/style.css to src/public/css/style.min.css on every change.

Other Commands

PurposeCommand
SSG with verbose loggingbun scripts/ssg.ts --public ./src/public --dist ./dist --verbose
SSG with hreflang linksbun scripts/ssg.ts --public ./src/public --dist ./dist --site-url https://example.com
CSS once (minified)bun css:build
CSS watchbun css:watch
Generate sitemapbun sitemap
Generate RSS feedbun rss
Format sourcebun format (uses reettier)

Verifying the Setup

cd __PROJECT_DIR__
bun ssg
bun preview

If you see "✓ Build complete" in the terminal and the preview loads at http://localhost:3000, everything is wired up correctly.

Editor Setup

For VSCode, .vscode/settings.json in this project maps .ree files to a custom language. For other editors, treating .ree as HTML gets you most of the way - the tag syntax ({= }, {#if}, {#each}) is distinct enough that the HTML highlighter ignores it cleanly.