Skip to content

Latest commit

 

History

History
40 lines (24 loc) · 725 Bytes

File metadata and controls

40 lines (24 loc) · 725 Bytes

BeforeRender

Register your hook method which is invoked before invoking render method.

Installation

Add this line to your application's Gemfile:

gem 'before_render'

And then execute:

$ bundle

Or install it yourself as:

$ gem install before_render

Usage

class SomeController < ApplicationController

  before_render :my_hooker_before_render, only: [...]

  def my_hooker_before_render
    # Invoked before render method.
  end
end

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/toshiyukihina/before_render.

License

The gem is available as open source under the terms of the MIT License.