Back to Skills

vanilla-rails-style

verified

Use when refactoring Ruby/Rails code, organizing methods, deciding on guard clauses vs if/else, or following 37signals conventions - these patterns are counter to standard Ruby style guides

View on GitHub

Marketplace

zemptime-marketplace

ZempTime/zemptime-marketplace

Plugin

vanilla-rails

Repository

ZempTime/zemptime-marketplace
1stars

vanilla-rails/skills/style/SKILL.md

Last Verified

January 20, 2026

Install Skill

Select agents to install to:

Scope:
npx add-skill https://github.com/ZempTime/zemptime-marketplace/blob/main/vanilla-rails/skills/style/SKILL.md -a claude-code --skill vanilla-rails-style

Installation paths:

Claude
.claude/skills/vanilla-rails-style/
Powered by add-skill CLI

Instructions

# Vanilla Rails Style

**These conventions CONTRADICT standard Ruby style guides.** They reflect production 37signals/Basecamp code.

## When to Use

You're writing Ruby/Rails code for 37signals-style projects. Symptoms that trigger this skill:
- Refactoring methods with guard clauses
- Organizing private methods in a class
- Deciding whether to add a bang to method name
- Structuring controllers and models
- Creating background jobs

## Counter-Intuitive Patterns

These patterns violate what most Ruby developers consider "best practice":

| Pattern | 37signals Way | Standard Ruby Way |
|---------|---------------|-------------------|
| Conditionals | Prefer if/else | Prefer guard clauses |
| Private indentation | Indent under `private` | No indentation (Rubocop) |
| Bang methods | Only with counterpart | Flag "dangerous" actions |
| Method order | Invocation sequence | Alphabetical |
| Controllers | Thin + rich models | Service objects |

## Red Flags - STOP and Reconsider

If you're about to do any of these, you're violating 37signals style:

| Red Flag | Instead, Do This |
|----------|------------------|
| Add guard clauses (`return unless`, `return if`) | Use if/else (unless at method start with complex body) |
| Remove indentation from private methods | Indent 2 spaces under `private` |
| Add bang to a method without counterpart | Use plain name (e.g., `close` not `close!`) |
| Alphabetize private methods | Order by invocation sequence |
| Create a service object as special artifact | Move logic to model, call from controller |

**These violations require explicit approval. Don't deviate without discussion.**

## Quick Reference

| Situation | 37signals Way | See Section |
|-----------|---------------|-------------|
| Early return needed? | if/else (or guard at method start if body complex) | Expanded Conditionals |
| Private methods? | Indent 2 spaces under `private` | Private Indentation |
| Ordering methods? | Invocation sequence (caller before callee) | Meth

Validation Details

Front Matter
Required Fields
Valid Name Format
Valid Description
Has Sections
Allowed Tools
Instruction Length:
9699 chars

Issues Found:

  • name_directory_mismatch