百科.dev
全部条目在线工具AI 编程趋势榜开源项目技术资讯提交条目
登录
< 返回工具列表
I

interactor-rails

> 后端框架
开源

Interactor Rails 为 Interactor gem 提供 Rails 支持。

452 stars0 点赞1 次浏览
访问官网GitHub

工具介绍

Interactor Rails 为 Interactor gem 提供 Rails 支持。

Interactor Rails

Interactor Rails provides Rails support for the Interactor gem.

Installation

Add this line to your application's Gemfile:

ruby
gem "interactor-rails", "~> 2.0"

Interactor Rails is tested against Ruby 3.1 and newer on Rails 7.0 or newer. For older versions of Ruby and Rails use version 2.2.1.

Usage

Interactor Rails ensures that app/interactors is included in your autoload paths, and provides generators for your convenience.

bash
rails generate interactor authenticate_user

adds to app/interactors/authenticate_user.rb:

ruby
class AuthenticateUser
  include Interactor

  def call
    # TODO
  end
end

There is also a generator for organizers.

bash
rails generate interactor:organizer place_order charge_card send_thank_you fulfill_order

adds to app/interactors/place_order.rb:

ruby
class PlaceOrder
  include Interactor::Organizer

  organize ChargeCard, SendThankYou, FulfillOrder
end

Contributions

Interactor Rails is open source and contributions from the community are encouraged! No contribution is too small.

See Interactor Rails' contribution guidelines for more information.

Thank You!

A very special thank you to Attila Domokos for his fantastic work on LightService. Interactor is inspired heavily by the concepts put to code by Attila.

Issues· 0 开放

查看全部 Issues在 GitHub 打开

暂无开放 Issues,或尚未同步最近议题。

> 标签

Rubyinteractorinteractor-railsrailsruby

暂无评论,来聊聊你的看法吧

> 工具信息

发布日期2026年8月1日
最后更新2026年9月17日
分类后端框架
定价开源

> 相关工具

N
Node.js
基于 V8 的 JavaScript 运行时
D
Django
Python 高级 Web 框架
S
Spring Boot
Java 生态主流微服务框架