SECURITY_SUPABASE.md Security
RLS as default-deny authorization, JWT custom claims for RBAC, MFA with AAL claim checking, service_role key protection, Edge Function input validation, Supabase Vault for secrets, PostgREST query filtering restrictions, and Realtime channel authorization.
When to use: Reference when writing RLS policies, configuring Supabase Auth, implementing Edge Function authorization, managing API key scoping, or auditing database role permissions.
SCALABILITY_SUPABASE.md Scalability
Supavisor connection pooling, database webhooks for async processing, pg_cron for scheduled work, queue patterns with pgmq, index strategy with EXPLAIN ANALYZE, read replicas, table partitioning, materialized views, and cursor-based pagination.
When to use: Reference when designing PostgreSQL schemas for scale, optimizing query performance, implementing background job processing, or planning for high-concurrency read/write workloads.
MAINTAINABILITY_SUPABASE.md Maintainability
Reusable RLS policy functions, typed Supabase client with generated types, pgTAP for database function tests, RLS policy testing, migration testing with supabase db reset, Edge Function tests with Deno, and integration tests against local Supabase.
When to use: Reference when organizing database functions, setting up RLS testing, writing migration files, configuring CI with the Supabase CLI, or generating TypeScript types from the database schema.
UIUX_SUPABASE.md UI/UX
Optimistic UI with Supabase client writes, Realtime confirmation via postgres_changes, Realtime Presence for collaboration, Broadcast for ephemeral events, partial loading for multi-query screens, and database-driven A/B testing.
When to use: Reference when implementing real-time features with Supabase Realtime, designing optimistic write patterns, building collaborative features with Presence, or setting up analytics via database inserts.
AVAILABILITY_SUPABASE.md Availability
Supabase read replicas, Storage CDN, automatic Realtime reconnection, pg_cron cleanup jobs, automated backups with PITR, backup verification, migration safety with guards, staged deployments, and deploy-from-CI discipline.
When to use: Reference when planning Supabase infrastructure for production, setting up backup and recovery, configuring connection pooling for availability, or designing deployment pipelines with rollback.
ADAPTABILITY_SUPABASE.md Adaptability
Translation tables in PostgreSQL, locale-aware full-text search with tsvector, ICU collations for sorting, accent-insensitive search with unaccent extension, trigram fuzzy matching with pg_trgm, and Edge Function pluralization with Intl.PluralRules.
When to use: Reference when adding localization to a Supabase-backed app, implementing full-text search with language support, configuring locale-specific sorting, or building fuzzy/accent-insensitive search.
CLEAN_CODE_SUPABASE.md Clean Code
Table and column naming in snake_case, descriptive RLS policy names, typed database functions, single-purpose Edge Functions, no side effects in RLS, idempotent webhook handlers, enum types over string constants, and no flag parameters.
When to use: Reference during all Supabase code writing and review. Essential for naming tables and policies, structuring Edge Functions, and ensuring database webhooks handle duplicate delivery.
ARCHITECTURAL_DESIGN_SUPABASE.md Architecture
Database-centric architecture with PostgreSQL as application server, schema organization (public vs. private), RLS policy architecture by access pattern, Edge Function structure, repository pattern, event-driven patterns with triggers and webhooks, and views as API contracts.
When to use: Reference when structuring a new Supabase project, designing the schema with public and private schemas, organizing RLS policies, or planning the event flow from client writes through triggers to Edge Functions.
SOURCE_STRUCTURE_SUPABASE.md Structure
Supabase project layout with migrations, Edge Functions, and tests. Migration file naming and ordering, RLS policy grouping, one Edge Function per directory, shared modules in _shared/, SQL formatting, seed data separation, and test mirroring.
When to use: Reference when setting up a new Supabase project, organizing migration files, structuring Edge Function directories, or establishing SQL formatting and naming conventions.
DOCUMENTATION_COMMENTS_SUPABASE.md Documentation
Commenting RLS policy intent, documenting denormalization and trigger chains, PostgreSQL extension usage context, descriptive migration filenames, schema documentation, RLS policy summary matrix, Edge Function API docs, and operational runbooks.
When to use: Reference when writing RLS policies, documenting schema decisions, creating operational runbooks, or establishing SQL comment standards for migrations and database functions.