Project Structure
Caspian follows a modern, package-driven architecture. The directory layout is lean, prioritizing your application code while core utilities are managed via the framework package.
Top-Level Overview
Your project is organized into three main areas: the
Application Source (src), the Database (prisma), and the Caspian Package.
src/
The heart of your application. Contains your routes, pages, styles, and libraries.
caspian-utils
The framework engine. Import Auth, RPC, and State tools directly
from the
casp package.
prisma/
Database schema and seed scripts. This is where you define your data models.
public/
Static assets like images, fonts, and compiled JS/CSS. Files here are served directly.
Directory Breakdown
- main.py
- caspian.config.json
-
prisma/
- schema.prisma // Database models
- seed.ts // Data seeding script
-
src/
-
app/ // File-based routing
- layout.html // Root layout
- index.py // Backend logic for "/"
- index.html // Template for "/"
- globals.css
- lib/ // Shared helpers & UI libraries
-
Key Files
src/app/index.py
The backend logic for your pages. Import
rpc and
auth from
casp here.
src/app/index.html
The visual template for your pages. This file supports standard HTML,
PulsePoint directives (pp-for), and component imports.
main.py
The entry point. Auth configuration that used to reside in
utils/ is now
handled here via
configure_auth().