Development Overview
Development Overview
Welcome to the Global Watch Development Guide. This section covers everything you need to know to set up your local development environment, understand our coding conventions, and start contributing to the codebase.
Quick Start
Get up and running with Global Watch development in minutes:
# 1. Clone the repository
git clone https://github.com/your-org/globalwatch.git
cd globalwatch
# 2. Install dependencies
pnpm install
# 3. Start local Supabase
pnpm supabase:web:start
# 4. Start the development server
pnpm devAfter running these commands, you'll have:
- Web App: http://app.localhost.direct:3000
- Marketing Site: http://localhost.direct:3000
- Supabase Studio: http://localhost.direct:54323
Technology Stack
Global Watch is built with modern technologies:
| Category | Technology |
|---|---|
| Framework | Next.js 16 (App Router, Turbopack) |
| Runtime | React 19, TypeScript 5.9+ |
| Database | Supabase (PostgreSQL with RLS) |
| Styling | Tailwind CSS 4, Shadcn UI |
| Monorepo | Turborepo with pnpm workspaces |
| Architecture | Hexagonal (Ports & Adapters) |
Development Sections
Setup Guide
Complete instructions for setting up your local development environment:
- Installing prerequisites (Node.js, pnpm, Docker)
- Configuring environment variables
- Starting local services (Supabase, development server)
- HTTPS development setup
Coding Conventions
Standards and best practices for contributing code:
- TypeScript conventions and type safety
- Component organization patterns
- File naming conventions
- Testing requirements
- Git commit message format
AI Agents Guide
Guidelines for AI agents (Claude, Amazon Q, Cursor) contributing to Global Watch:
- The 7 Absolute Laws (zero tolerance rules)
- RITO Methodology for structured development
- Package conventions (@kit vs @fw)
- Multi-agent collaboration patterns
- Pre-commit checklist
Common Commands
Here are the most frequently used commands during development:
Development
# Start all apps with Turbopack
pnpm dev
# Start with HTTPS (requires Caddy)
pnpm dev:https
# Start only the web app
pnpm --filter web dev
# Start only the docs site
pnpm docs:devDatabase
# Start local Supabase
pnpm supabase:web:start
# Stop Supabase
pnpm supabase:web:stop
# Reset database (apply migrations)
pnpm supabase:web:reset
# Generate TypeScript types
pnpm supabase:web:typegen
# Create a new migration
pnpm --filter web supabase:db:diff <migration-name>Quality Assurance
# Type checking
pnpm typecheck
# Lint and auto-fix
pnpm lint:fix
# Format code
pnpm format:fixTesting
# Run unit tests
pnpm --filter web test:run
# Run E2E tests
pnpm --filter e2e testBuild
# Build all apps
pnpm build
# Build web app only
pnpm --filter web build
# Build docs site
pnpm docs:buildPackage Conventions
Global Watch uses two package namespaces:
| Namespace | Purpose | Location |
|---|---|---|
@kit/* | Makerkit base packages (do not modify) | packages/ |
@fw/* | Global Watch custom packages | packages/fw/ |
@fw Packages
When creating new functionality, always use the @fw namespace:
// ✅ CORRECT - Our custom code
import { PasswordInput } from '@fw/ui/password-input';
import { EntitySettings } from '@fw/entity-settings';
// ❌ WRONG - Don't create in @kit
import { MyCustom } from '@kit/ui/my-custom';Environment Variables
All environment variables are centralized at the monorepo root:
/ # Monorepo root
├── .env # Shared base config (committed)
├── .env.development # Development defaults (committed)
├── .env.local # Local overrides (gitignored)
└── apps/ # NO .env files in apps/Important: Never create .env files inside apps/ directories.
Learn more about Environment Variables →
Development Workflow
The recommended workflow for feature development:
- Create a branch from
main - Read the relevant documentation before coding
- Write tests first (TDD approach)
- Implement the feature following conventions
- Run quality checks (
pnpm typecheck && pnpm lint:fix) - Test manually in the browser
- Create documentation for new features
- Submit a pull request
Getting Help
If you encounter issues during development:
- Check the Setup Guide for common issues
- Review the Architecture Documentation for design questions
- Search existing GitHub issues
- Ask in the team communication channel
Next Steps
- Setup Guide - Configure your development environment
- Conventions - Learn our coding standards
- AI Agents Guide - Guidelines for AI contributors
- Architecture Overview - Understand the system design