dhh-rails-style

Apply DHH Rails conventions to controllers, models, and views.

Updated Mar 26, 2026
One-click install
npx skills add https://github.com/jaydubya818/New_baseline --skill dhh-rails-style-jaydubya818
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: dhh-rails-style
Source: https://github.com/jaydubya818/New_baseline/tree/main/skills/compound-engineering/plugins/compound-engineering/skills/dhh-rails-style
Command: npx skills add https://github.com/jaydubya818/New_baseline --skill dhh-rails-style-jaydubya818

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

The guidance helps teams craft Ruby and Rails code following 37signals/DHH style, promoting readable, maintainable, and RESTful designs with fat models, lean controllers, and principled architecture.

Core Features & Use Cases

  • Enforces controller-centric RESTful structure with resource-specific controllers and concerns
  • Guides model composition using concerns and state-as-records for traceability
  • Recommends Turbo/Stimulus-based frontend without heavy JS frameworks
  • Applies during code generation, refactoring, or code reviews to ensure consistent style

Quick Start

Review your Rails project and align controllers, models, and views with DHH conventions.

Frequently Asked Questions about dhh-rails-style

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

FAQPage Schema
What are DHH Rails conventions for structuring controllers and models?

DHH Rails conventions favor lean controllers and fat models using concerns for state management. This 37signals approach keeps Ruby on Rails codebases RESTful, readable, and maintainable during code generation and refactoring.

How do I refactor a Rails controller to follow 37signals style?

Refactor Rails controllers by moving business logic into fat models and concerns, keeping them lean and resource-specific. Apply this during code generation or reviews to enforce RESTful structure and model-centered state.

Does the DHH Rails style use Turbo and Stimulus for frontend architecture?

Yes, DHH Rails conventions recommend a Turbo and Stimulus-based frontend without heavy JavaScript frameworks. This keeps Rails views integrated with server-side logic while maintaining interactive functionality.

When should I use concerns in Rails models according to DHH conventions?

Use concerns in Rails models to compose model-centered state and maintain traceability. DHH conventions guide model composition using concerns to keep fat models readable and principled without bloating core ActiveRecord classes.

What is the best way to enforce RESTful design in a Ruby on Rails codebase?

Enforce RESTful design by applying DHH Rails conventions with resource-specific controllers, lean controller logic, and database-backed architecture. This skill codifies patterns to guide production code during refactoring and reviews.