Getting Started

This guide will help you get up and running with Taxus quickly.

Prerequisites

Before you begin, ensure you have the following installed:

Quick Start

Step 1: Clone and Initialize

# Clone the repository
git clone https://github.com/crustyrustacean/taxus.git
cd taxus

# Create a new site
cargo run -- init my-site --name "My Site" --base-url "https://example.com"

This creates the following structure:

my-site/
├── site.toml               # Site configuration
├── content/
│   └── _index.md           # Home page
├── templates/
│   ├── base.html           # Base HTML layout
│   ├── page.html           # Single-page template
│   ├── section.html        # Section/listing template
│   ├── tags.html           # Tag listing page
│   ├── tags_term.html      # Individual tag page
│   ├── categories.html     # Category listing page
│   ├── categories_term.html # Individual category page
│   ├── series.html         # Series listing page
│   ├── series_term.html    # Individual series page
│   └── 404.html            # Not found page
├── static/
│   ├── scripts.js          # Placeholder scripts
│   └── favicon.png         # Placeholder favicon
└── styles/
    └── main.scss           # Starter stylesheet

Step 2: Build the Site

cargo run -- build --dir my-site --verbose

This runs the 13-stage build pipeline and writes output to my-site/dist/.

Step 3: Serve and View

cargo run -- serve --dir my-site --open

This starts a development server at http://localhost:3000 and opens it in your browser.

You should see the home page rendered from the Markdown content in content/_index.md.

Next Steps

For Islands Support

If you want interactive Yew components:

# Initialize with islands support
cargo run -- init my-site --islands

# Build with islands feature enabled
# The WASM client is compiled automatically and embedded in the binary
cargo run --features islands -- build --dir my-site

The WASM client (client.js and client_bg.wasm) is compiled during the Cargo build and written to dist/wasm/ automatically — no separate build step is needed.

See Islands Architecture for the complete guide.