dhh-rails-style

Apply DHH and 37signals Rails conventions to Ruby code.

Updated Aug 27, 2026
One-click install
npx skills add https://github.com/greatxrider/nomanuAI --skill dhh-rails-style-greatxrider
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: dhh-rails-style
Source: https://github.com/greatxrider/nomanuAI/tree/main/.claude/plugins/compound-engineering/2.31.1/skills/dhh-rails-style
Command: npx skills add https://github.com/greatxrider/nomanuAI --skill dhh-rails-style-greatxrider

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill helps developers write Ruby and Rails code that adheres to the distinctive, pragmatic, and efficient style championed by David Heinemeier Hansson (DHH) and used at 37signals.

Core Features & Use Cases

  • Convention Adherence: Applies core 37signals philosophies like "fat models, thin controllers," REST purity, and database-centric solutions.
  • Code Refinement: Refactors existing Ruby/Rails code to align with DHH's preferred patterns, avoiding common "enterprise" abstractions.
  • Use Case: When refactoring a Rails controller that has grown too large, this Skill can help break it down into smaller, more manageable parts following the "thin controller" principle, potentially by moving logic into model concerns or using Turbo Streams for updates.

Quick Start

Apply DHH's Rails conventions to the provided Ruby code snippet.

Frequently Asked Questions about dhh-rails-style

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
What is DHH's Rails coding style and how does it differ from common enterprise patterns?

DHH's Rails style favors fat models, thin controllers, REST purity, and database-centric solutions, prioritizing clarity over cleverness while avoiding common enterprise abstractions like excessive service objects.

How do I refactor a Rails controller to follow the thin controller principle?

Refactor bloated Rails controllers by moving logic into model concerns or using Turbo Streams for updates, adhering to the 37signals convention of fat models and thin controllers for clearer code.

When should I use Current attributes in Ruby on Rails applications?

Use Current attributes in Rails to hold global request context like the current user or account, replacing traditional parameter passing with a thread-local pattern championed by 37signals production codebases.

What are the best Hotwire patterns for Rails views and updates?

Hotwire patterns in DHH's style involve using Turbo Streams for targeted page updates and avoiding heavy JavaScript frameworks, keeping Rails applications pragmatic and server-rendered.

Does this coding style work with existing Ruby applications that use service objects?

This style challenges heavy service object abstractions by refactoring them back into fat models and concerns, applying 37signals philosophies of domain logic placement over enterprise-level indirection.