Naming Conventions
How to name apps, files, tables, variables, and environment variables in the monorepo.
Consistent naming is how the monorepo stays navigable across 30+ apps. Follow these conventions when you create files, tables, or variables — and when in doubt, look at how existing apps do it.
Quick Reference
| Item | Convention | Example |
|---|---|---|
| App directory | kebab-case | apps/checkin-board/ |
| Database table (app-specific) | snake_case, app-prefixed | checkin_board_checkin |
| Database table (shared) | semantic prefix | class_user, log_activity |
| Component file | PascalCase.tsx | UserProfile.tsx |
| Utility file | camelCase.ts | formatDate.ts |
| API route folder | kebab-case | app/api/user-profile/route.ts |
| Page route folder | kebab-case | app/user-settings/page.tsx |
| Variable | camelCase | userName, totalCount |
| Function | camelCase (verb-noun) | getUserData(), calculateTotal() |
| Constant | UPPER_SNAKE_CASE | MAX_RETRY_ATTEMPTS |
| React Hook | useCamelCase | useUserData() |
| CSS class | kebab-case | user-card |
| Environment variable | UPPER_SNAKE_CASE | DATABASE_URL, AUTH_UI_URL |
| Package name | kebab-case | "name": "checkin-board" |
Apps
Use kebab-case — lowercase, hyphen-separated:
- ✅
checkin-board,breakfast-tracker,meal-planner - ❌
CheckinBoard,checkin_board,checkinBoard
The app directory, the name field in package.json, and the root scripts (dev:<app-name>, build:<app-name>, start:<app-name>) must all match.
Database Tables
App-specific tables are prefixed with the app name in snake_case:
{app_name}_{table_name}
Convert the app's kebab-case name to snake_case: checkin-board → checkin_board_*.
| App | Example table |
|---|---|
checkin-board | checkin_board_checkin |
breakfast-tracker | breakfast_tracker_meal |
meal-planner | meal_planner_recipe |
Shared tables (used by multiple apps) use semantic prefixes instead: class_user, log_activity, map_*. See Database for the full schema workflow.
Environment Variables
Use UPPER_SNAKE_CASE. For app-specific GitHub secrets that map into Railway, prefix with the app name in snake_case:
BREAKFAST_TRACKER_SLACK_WEBHOOK_URLRECRUIT_ASHBY_API_KEYSTAFF_MEAL_TRACKER_OPENAI_API_KEY
This keeps GitHub variables collision-free across 30+ apps. See Environment Variables for how these map to Railway.
Next.js public variables (exposed to the browser) prefix with NEXT_PUBLIC_ — NEXT_PUBLIC_API_URL.
Ask Claude
Quiz
Which of these is the correct table name for a 'reservations' table in the 'checkin-board' app?