stimulus-rails integrates the Stimulus JavaScript framework into Rails, providing a lightweight, declarative way to enhance server-rendered HTML with dynamic behavior. It complements Turbo as part of the Hotwire stack.

Setup requires adding the gem, running the installer, and writing Stimulus controllers that map directly to DOM elements. It supports the latest versions of Rails on Ruby 3+, and is actively maintained by the Rails core team.