rails-performance
Installation
SKILL.md
Rails performance
From the Rails guides, plus the performance cops that large codebases (GitLab) enable on purpose — those exist because each one was a real incident.
N+1 queries — the default failure mode
The most common Rails performance bug, and the easiest to introduce without noticing. A view loop over a relation, touching an association per record, is N+1 by default.
@orders.each { |o| o.line_items.count } # 1 + N queries
Detect it, do not guess. In development: