Playbook

The Modh Playbook

How we build production software. Every pattern, convention, and decision — from database queries to component architecture — distilled from real projects.

00

Foundations

Tech stack selection, project philosophy, and the principles behind every decision.

Tech Stack Selection

00

Why every tool in our stack exists, and why yours might be different

18 minbeginner
01

Data Layer

Database standards, repository patterns, server actions, and data fetching strategies.

The Repository Pattern

01

Why we never write raw database queries

8 minintermediate

Server Actions

02

Type-safe mutations that just work

7 minintermediate

Data Fetching

03

Server Components changed everything

7 minintermediate

Database Standards

04

Schema-first, types-generated, RLS-enforced

8 minintermediate
02

Architecture

Route colocation, caching, multi-tenant isolation, and webhook design.

Route Colocation

04

Files live next to the route that uses them

8 minintermediate

Webhook Architecture

05

Building webhooks that never lose events

9 minadvanced

Multi-Tenant Security

07

RLS: the database does the auth checking

8 minadvanced

Caching Strategy

08

How we think about cache invalidation

7 minintermediate
03

Quality

Testing strategy, TypeScript strict mode, CI pipelines, and incident response.

CI Pipeline

06

5-second CI that catches everything

7 minintermediate

Testing Philosophy

07

What we test and why — confidence over coverage

8 minintermediate

TypeScript Strict

07

Zero any, generated types, strict mode always on

9 minintermediate

Testing Patterns

08

Factories, mocking, and integration tests that prove it works

10 minintermediate

Code Quality Audit

09

Systematic route audits that find dead code, wrong abstractions, and missing tests

12 minadvanced

Incident Response

09

When things break: our runbook

9 minintermediate

Code Review

10

AI-assisted reviews that teach, not just gatekeep -- seven dimensions, three severities, zero ambiguity

14 minintermediate
04

Security

Row-level security, input validation, security headers, and data lifecycle.

Input Validation

10

Zod schemas at every boundary

9 minintermediate

Security Architecture

10

Defense in depth for multi-tenant SaaS

10 minadvanced

Row Level Security Deep Dive

11

Row Level Security as your authorization layer

11 minadvanced

Data Lifecycle

12

Retention, rotation, and responsible deletion

9 minadvanced

Security Headers

12

CSP, CORS, and webhook signature verification

8 minintermediate
05

Observability

Structured logging, error tracking, performance monitoring, and webhook observability.

Webhook Observability

15

Every webhook traced end-to-end with searchable tags

9 minadvanced

Structured Logging

17

Logs that tell a story

8 minintermediate

Distributed Tracing

18

Following a request across 6 services

9 minadvanced

Performance Monitoring

19

Measuring what matters

7 minintermediate
06

Process

Agentic development, decision velocity, documentation, and project scoping.

Feature Design

17

Think before you code — 2-3 approaches, then decide

8 minintermediate

Linear Tickets

18

User stories, architecture context, sub-task breakdown

8 minbeginner

Pull Requests

19

CI passes first, then a rich description with test plan

7 minbeginner

Project Scoping

20

How we estimate and ship on time

7 minbeginner

Decision Velocity

21

One-way doors vs two-way doors

7 minbeginner

Documentation as Code

22

Three-layer docs for humans + AI

8 minintermediate

Agentic Development

23

Building with AI agents, not against them

12 minadvanced

Progressive Loading

24

The user should never wait

9 minintermediate
07

Frontend Craft

Component architecture, design standards, performance patterns, and internal tools.

Component Architecture

00

Composition over configuration

5 minintermediate

Frontend Performance

00

Suspense, streaming, and instant UI

5 minintermediate

Design Standards

22

shadcn/ui, semantic tokens, premium by default

9 minintermediate

Internal Tools

24

Data density over visual impact, scannability first

8 minintermediate
Modh

We build software. Accelerate your engineers. And do AI, the right way.

info@modh.ca
ServicesBlogCareers
Accepting engagements

© 2026 Modh. All rights reserved.