Installation
Get started with Rejoice in just a few steps.
Prerequisites
Before you begin, make sure you have the following installed:
- Rust (1.85 or later) - Install Rust
- Node.js (18 or later) - Install Node.js
Install the CLI
Install the Rejoice CLI globally using Cargo:
cargo install rejoice
This gives you access to the rejoice command for creating and managing projects.
Create a New Project
Create a new Rejoice project:
rejoice init my-app
cd my-app
This creates a new directory with a complete project structure including:
- Rust source files with example routes
- Vite configuration for client-side assets
- Tailwind CSS setup
- An example SolidJS island component
With Database Support
If you need SQLite database support:
rejoice init my-app --with-db
This additionally creates:
- A
.envfile withDATABASE_URL - An empty SQLite database file
AppStatestruct with a connection pool
Start the Dev Server
Run the development server:
rejoice dev
Your app is now running at http://localhost:8080.
The dev server includes:
- Automatic Rust recompilation - Changes to
.rsfiles trigger a rebuild - Vite watch mode - Client-side assets rebuild automatically
- Live reload - Your browser refreshes when changes are detected
Build for Production
When you're ready to deploy:
rejoice build --release
This creates an optimized binary at target/release/my-app along with the compiled client assets in dist/.
Next Steps
- Project Structure - Understand how your project is organized
- Routing - Learn about file-based routing
- Templates - Write HTML with Maud