Sha256: b31113735546db52bd13342c794de6d54ea46fc3aa8ee0f1ddf8b21e23d6d68d

Contents?: true

Size: 433 Bytes

Versions: 4

Compression:

Stored size: 433 Bytes

Contents

require 'danthes/view_helpers'

module Danthes
  class Engine < Rails::Engine
    # Loads the danthes.yml file if it exists.
    initializer 'danthes.config' do |app|
      path = app.root.join('config/danthes.yml')
      ::Danthes.load_config(path) if path.exist?
    end

    # Adds the ViewHelpers into ActionView::Base
    initializer 'danthes.view_helpers' do
      ActionView::Base.send :include, ViewHelpers
    end
  end
end

Version data entries

4 entries across 4 versions & 2 rubygems

Version Path
edmond-danthes-2.1.1 lib/danthes/engine.rb
edmond-danthes-2.1.0 lib/danthes/engine.rb
danthes-2.0.1 lib/danthes/engine.rb
danthes-2.0.0 lib/danthes/engine.rb