readysite / docs / README.md
4.9 KB
README.md

ReadySite

An open-source platform that makes it easy for anyone to build, launch, and manage websites. AI lets you create software — ReadySite gets it live.

Ready, Site, Go!

Vision

  • Build - Create websites with templates or from scratch
  • Test - Preview and validate before going live
  • Manage - Dashboard for all your websites in one place
  • Host - Deploy to cloud infrastructure with one click

Architecture

Five layers, each independent and composable:

Layer Status Purpose Key Abstraction
Database Type-safe SQLite CRUD Collection[E] - generic repository
Application MVC web framework Controller - handles HTTP + templates
Frontend Interactive islands Frontend - esbuild bundler + HMR
Platform Cloud deployment Platform - provider-agnostic infrastructure
Assistant AI provider abstraction Assistant - OpenAI, Anthropic, mock

Quick Start

// main.go
package main

import (
    "embed"
    "github.com/readysite/readysite/example/controllers"
    "github.com/readysite/readysite/pkg/application"
)

//go:embed views
var views embed.FS

func main() {
    application.Serve(views,
        application.WithController(controllers.Home()),
    )
}
# Build and run
go build -o app && ./app

# Deploy to cloud
go build -o build/launch ./cmd/launch
./build/launch --new myapp

Design Philosophy

  1. Server-Side Rendering - HTMX/HATEOAS, no client-side state
  2. Type Safety - Generics, string UUIDs, PascalCase SQL
  3. Thin Controllers - HTTP handling only, logic in internal/
  4. Minimal Abstractions - Explicit over clever
  5. Production Ready - Built-in deployment, security defaults

AI-First Development

ReadySite is optimized for AI-assisted development with human review:

Traditional Framework ReadySite
Hide complexity Expose explicit patterns
Magic & conventions Predictable, traceable code
Framework-specific DSLs Standard SQL, Go, HTML
Human writes, human debugs AI writes, human reviews

Why this matters:

  • Explicit patterns → AI generates correctly
  • Type safety → Compiler catches AI mistakes before review
  • Standard SQL → AI's strongest query language, not a custom ORM DSL
  • Minimal abstractions → Human reviews what actually runs

Project Structure

pkg/
├── database/       # Collection[E], Model, engines
├── application/    # App, Controller, views, routing
├── frontend/       # Frontend, esbuild bundler, HMR
├── platform/       # Server, Volume, DNS, providers
└── assistant/      # AI chat, tools, providers

cmd/
├── launch/         # Deploy to servers
├── connect/        # SSH to servers
└── publish/        # Build and push Docker images

example/            # Minimal example app
├── main.go
├── controllers/
└── views/

website/            # AI-native CMS
├── main.go
├── controllers/    # 14 controllers including AI chat
├── models/         # Pages, Collections, Documents, Conversations
├── views/          # Admin UI + public rendering
└── internal/       # Tools, schema, access control

Key Conventions

Rule Example
IDs are strings "uuid-here" not 123
SQL uses PascalCase WHERE UserID = ?
Templates by filename {{template "card.html" .}}
Controller access {{home.Method}} not {{.home.Method}}
Zero value defaults cmp.Or(value, "default")

Frontend Stack

Library Version CDN
DaisyUI 5 https://cdn.jsdelivr.net/npm/daisyui@5
Tailwind CSS 4 https://cdn.jsdelivr.net/npm/@tailwindcss/browser@4
HTMX 2.0.8 https://cdn.jsdelivr.net/npm/htmx.org@2.0.8

Documentation

Core Layers

  • Database - Collections, queries, engines
  • Application - Controllers, templates, SSE streaming
  • Frontend - Interactive islands, esbuild, HMR
  • Platform - Servers, deployment, CLI commands
  • Assistant - AI providers, tool calling, streaming

Applications

Guides

  • Deployment - infra.json, Dockerfiles, environment setup
  • Security - Authentication, rate limiting, input validation
  • Testing - Database, controller, and AI testing patterns
  • Examples - Recipes and code patterns
  • Troubleshooting - Common issues and solutions

Reference

← Back