GithubHelp home page GithubHelp logo

isabella232 / interactor-rails Goto Github PK

View Code? Open in Web Editor NEW

This project forked from collectiveidea/interactor-rails

0.0 0.0 0.0 56 KB

Interactor Rails provides Rails support for the Interactor gem.

License: MIT License

Ruby 94.38% HTML 5.62%

interactor-rails's Introduction

Interactor Rails

Gem Build Coverage Maintainability

Interactor Rails provides Rails support for the Interactor gem.

Installation

Add this line to your application's Gemfile:

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

Interactor Rails is compatible with Ruby 2.3, 2.4, or 2.5 on Rails 4.2, 5.0, 5.1, 5.2 or 6.0.

Usage

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

rails generate interactor authenticate_user

adds to app/interactors/authenticate_user.rb:

class AuthenticateUser
  include Interactor

  def call
    # TODO
  end
end

There is also a generator for organizers.

rails generate interactor:organizer place_order charge_card send_thank_you fulfill_order

adds to app/interactors/place_order.rb:

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.

interactor-rails's People

Contributors

laserlemon avatar gaffneyc avatar danielmorrison avatar sferik avatar andrewbredow avatar emilford avatar gambala avatar georgekaraszi avatar fauxparse avatar olleolleolle avatar ersatzryan avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.