BeforeMerge
FeaturesExploreSkillsPricingBlogDocs
Sign In
FeaturesExploreSkillsPricingBlogDocs
Sign In
BeforeMerge

AI-native code review knowledge base. Structured rules that catch what linters miss.

Product

  • Features
  • Explore
  • Pricing
  • Docs
  • GitHub

Company

  • About
  • Blog
  • Contributing

Legal

  • Privacy Policy
  • Terms of Service
  • MIT License

© 2026 BeforeMerge. Built by Peter Krzyzek

Explore

Browse 158 rules, 25 knowledge articles, and 25 prompt templates across security, performance, architecture, and quality.

158 rules

Use Consistent ServiceResult Type for All Service Returns

MEDIUM

Inconsistent error handling with thrown exceptions, returned nulls, and ad-hoc error objects makes callers fragile. Use a discriminated union ServiceResult type.

discriminated-unionservice-result
beforemerge-fullstack-architecture-review

Do Not Mix Controlled and Uncontrolled Input Patterns

MEDIUM

Switching between controlled (value prop) and uncontrolled (defaultValue/no value) patterns on the same input causes React warnings and unpredictable behavior.

controlled-componentsforms
beforemerge-react-review

Distinguish Not-Found from Other Supabase Errors

MEDIUM

Treating all Supabase errors the same (if error, throw) hides whether a record is missing or the query itself failed. Check error codes for proper handling.

postgrestsupabase
beforemerge-supabase-review

Eliminate Prop Drilling Through 3+ Component Levels

MEDIUM

Passing props through 3+ levels of intermediate components that don't use them creates tight coupling and maintenance burden. Use context, composition, or state management.

ReactContext
beforemerge-react-review

Use Scoped Loggers with Structured Context

MEDIUM

Bare console.log statements with no context make production debugging impossible. Use scoped loggers with errorId, userId, and structured metadata.

productionquality
beforemerge-fullstack-architecture-review

Implement loading.tsx and error.tsx at Every Route Segment

MEDIUM

Missing loading.tsx causes full-page spinners instead of granular streaming. Missing error.tsx lets errors crash parent layouts instead of being contained.

nextjssuspense
beforemerge-nextjs-review

Avoid Stale Closure Bugs in Hooks and Callbacks

MEDIUM

Event handlers and effects that capture state in closures can reference outdated values, causing silent data corruption and missed updates.

useeffectnextjs
beforemerge-nextjs-review

Add Error Boundaries Around Unreliable UI Sections

MEDIUM

Without error boundaries, a single component crash unmounts the entire React tree. Wrap unreliable sections so failures are isolated and recoverable.

reliabilityReact
beforemerge-react-review

Build Features Bottom-Up from Domain to Presentation

MEDIUM

Build in dependency order: Domain, Interface, Repository, Service, Controller, Presentation. Top-down builds couple UI to data.

planningarchitecture
beforemerge-fullstack-architecture-review

Never Use Array Index as Key for Dynamic Lists

MEDIUM

Using array index as key in lists that can be reordered, filtered, or inserted into causes React to mismap state to the wrong items, creating subtle and hard-to-debug UI bugs.

key-propreconciliation
beforemerge-react-review

Make All User-Facing Strings Translatable

MEDIUM

Hardcoded English strings prevent localization. Use __(), _e(), and esc_html__() with a text domain. Always escape translated output — translators can inject HTML.

wordpresslocalization
beforemerge-wordpress-review

Version Your API

MEDIUM

Version your API from day one (URL prefix, header, or query param). Without versioning, any breaking change forces all clients to update simultaneously or breaks them without warning.

RESTarchitecture
API Design Review

Never Expose Raw Errors or Stack Traces to Clients

MEDIUM

Returning raw error messages or stack traces leaks implementation details. Return generic messages with a requestId for server-side debugging. [CWE-209]

nextjsinformation-disclosure
beforemerge-fullstack-architecture-review

Segregate Repository Interfaces by Consumer Need

MEDIUM

Split large repository interfaces into focused, role-specific contracts so consumers only depend on the methods they use

interface-segregationsolid
beforemerge-fullstack-architecture-review

Automate these checks on every PR

BeforeMerge scans your pull requests against these rules automatically. Get actionable feedback before code ships to production.

Join WaitlistLearn More

Filters

Skill

Impact

Category

Skill

Impact

Category

Previous1234567Next