Sha256: fcccae87e090e8d8ad290be7c336147297c0213a4f87042c4568f9c5a1f538b8

Contents?: true

Size: 828 Bytes

Versions: 6

Compression:

Stored size: 828 Bytes

Contents

module BrighterPlanet
  class Layout
    class Railtie < ::Rails::Railtie
      rake_tasks do
        load 'brighter_planet_layout/rake_tasks.rb'
      end
      initializer 'brighter_planet_layout' do |app|
        app.paths.app.views.push ::BrighterPlanet.layout.view_path
        if ::BrighterPlanet.layout.serve_static_files_using_rack?
          app.middleware.use '::ActionDispatch::Static', ::BrighterPlanet.layout.public_path
        end
        if ::BrighterPlanet.layout.copy_static_files?
          ::BrighterPlanet.layout.copy_static_files_to_web_server_document_root
        end
      end
      config.to_prepare do
        require ::BrighterPlanet.layout.helper_file
        ::ApplicationController.helper ::BrighterPlanetHelper
        ::ApplicationController.layout 'brighter_planet'
      end
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
brighter_planet_layout-0.3.16 lib/brighter_planet_layout/railtie.rb
brighter_planet_layout-0.3.15 lib/brighter_planet_layout/railtie.rb
brighter_planet_layout-0.3.14 lib/brighter_planet_layout/railtie.rb
brighter_planet_layout-0.3.13 lib/brighter_planet_layout/railtie.rb
brighter_planet_layout-0.3.12 lib/brighter_planet_layout/railtie.rb
brighter_planet_layout-0.3.11 lib/brighter_planet_layout/railtie.rb