vanilla-rails-views

Standardize Webpack-powered React component development with Storybook's workflow.

3|Updated Dec 25, 2025
One-click install
npx skills add https://github.com/ZempTime/zemptime-marketplace --skill vanilla-rails-views
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: vanilla-rails-views
Source: https://github.com/ZempTime/zemptime-marketplace/tree/main/vanilla-rails/skills/views
Command: npx skills add https://github.com/ZempTime/zemptime-marketplace --skill vanilla-rails-views

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill standardizes and simplifies Rails view templates, ERB usage, and Turbo/Stimulus integration to reduce duplication and boost consistency.

Core Features & Use Cases

  • Partial Organization: Place shared partials at the highest common directory to minimize redundancy.
  • Explicit Locals: Use local_assigns.fetch with defaults to avoid silent nil values.
  • CSS Class Helpers: Build dynamic class strings with compact arrays and helpers like token_list.
  • Collection Rendering: Cache and render collections efficiently with as: and cached options.
  • Turbo Streams & Stimulus: Apply Turbo Streams updates and layered Stimulus controllers in views.

Quick Start

Apply these conventions in your Rails app to structure app/views, reuse partials, and implement predictable view logic.

Frequently Asked Questions about vanilla-rails-views

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

FAQPage Schema
How do I organize Rails partials to avoid view duplication across controllers?

Standardize Rails ERB views by using local_assigns.fetch with defaults to avoid silent nil values. This enforces explicit locals in partials, ensuring robust and predictable view rendering without undefined variable errors.

What is the best way to render collections in Rails ERB for cache efficiency?

Render collections efficiently by using the as: option alongside cached options in Rails ERB. This pattern enables cache-friendly collection rendering, improving performance and maintainability for large list views.

How do I compose dynamic CSS classes in Rails view helpers?

Yes, Turbo Streams work with Rails ERB views by applying Turbo Streams updates alongside layered Stimulus controllers. This integration standardizes dynamic UI updates and view-layer interactions across controllers.

Do I need specific dependencies to standardize Turbo Streams and Stimulus in views?

No dependencies are required to standardize Turbo Streams and Stimulus integration in Rails views. The skill applies conventions for view templates, partial sharing, and local variable handling natively within Rails.