rails-style

Apply Rails Style Guide conventions during Rails code reviews and development workflows.

Updated Jan 28, 2026
One-click install
npx skills add https://github.com/shubhamtaywade82/trading_playground --skill rails-style
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: rails-style
Source: https://github.com/shubhamtaywade82/trading_playground/tree/main/.cursor/skills/ruby/rails
Command: npx skills add https://github.com/shubhamtaywade82/trading_playground --skill rails-style

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This skill standardizes Rails code practices by applying a formal style guide to ensure consistency, readability, and maintainability across projects.

Core Features & Use Cases

  • Guided front-end and back-end conventions: Config structures in config/, routing, controllers, models, and views follow consistent patterns.
  • MVC discipline and testing: Encourages skinny controllers, appropriate before_actions, and AR-centric business logic.
  • Use Case: When reviewing a Rails app, apply these rules to align initializers, environments, routing, and Active Record usage with the guide.

Quick Start

Review a Rails project to apply the Rails Style Guide. For example, ensure config/initializers has one file per gem, routing uses member/collection or namespace, and controllers stay slim.

Frequently Asked Questions about rails-style

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

FAQPage Schema
How do I enforce Rails conventions for routing and controllers?

To enforce Rails conventions, apply a formal style guide ensuring routing uses member/collection or namespace, and controllers stay slim with appropriate before_actions. This maintains MVC discipline and consistent config structures across your Rails project.

What are the best practices for organizing Rails initializers and environments?

Rails best practices for initializers dictate having exactly one file per gem in config/initializers. Consistent configuration patterns should also be applied across different environment files to ensure readability and maintainability.

How do I apply a Ruby style guide during Rails code reviews?

Apply a Rails style guide during code reviews to align Active Record usage and business logic with conventions. This ensures models remain AR-centric and satisfies documentation requirements through YAML frontmatter and Markdown outlines.

Does this Rails style guide work with rubocop-rails configurations?

This style guide complements rubocop-rails by enforcing MVC discipline and architectural conventions beyond automated linting. It manually guides config structures, routing, controllers, and Active Record usage during development workflows.

When do I need a formal style guide for my Rails project?

You need a formal Rails style guide when standardizing code practices across a growing project to ensure consistency. It is applied during development workflows and code reviews to align initialization, routing, and Active Record usage.