hotwire

Add Hotwire and Stimulus interactivity to Rails views with Importmap.

Updated Dec 13, 2024
One-click install
npx skills add https://github.com/apdarr/lace --skill hotwire-apdarr
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: hotwire
Source: https://github.com/apdarr/lace/tree/main/.github/skills/hotwire
Command: npx skills add https://github.com/apdarr/lace --skill hotwire-apdarr

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Enables Rails developers to add dynamic, SPA-like interactivity to server-rendered HTML without requiring heavy client-side frameworks.

Core Features & Use Cases

  • Turbo Drive, Turbo Frames, Turbo Streams, and Turbo Morph for navigation, partial updates, and real-time UI changes
  • Stimulus controllers for lightweight client-side behavior, data binding, and component state
  • Importmap-based JS management and optional SortableJS for drag-and-drop interactivity in Rails apps
  • Use cases include live updates, modal dialogs, inline editing, and drag-and-drop interfaces

Quick Start

Add a Stimulus controller to a view and enable Turbo Drive to begin interactivity.

Frequently Asked Questions about hotwire

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

FAQPage Schema
How do I add SPA-like interactivity to server-rendered Rails views?▼

You can add SPA-like interactivity to server-rendered Rails views by using Hotwire and Stimulus controllers to build dynamic experiences within HTML without heavy client-side frameworks.

What is the best way to handle partial page updates and live UI changes in Rails?▼

The best way to handle partial updates and live UI changes in Rails is using Turbo Drive, Turbo Frames, Turbo Streams, and Turbo Morph for navigation and real-time interface modifications.

How do I manage drag-and-drop interactivity in a Rails application?▼

You can manage drag-and-drop interactivity in Rails by integrating optional SortableJS alongside Stimulus controllers to handle component state and lightweight client-side behavior.

Do I need a heavy JavaScript framework to build modal dialogs and inline editing in Rails?▼

No, you do not need a heavy JavaScript framework to build modal dialogs and inline editing. You can achieve these dynamic experiences using Hotwire, Stimulus, and Importmap-based JS management.

How does Stimulus handle client-side behavior and data binding in a Rails frontend stack?▼

Stimulus handles client-side behavior and data binding in a Rails frontend stack by providing lightweight controllers that manage component state directly within server-rendered HTML.