Sha256: 6d9b945daa73e79e09cfb5b507ea4642c58c05fa3722deb625246a8ff9bd8944

Contents?: true

Size: 433 Bytes

Versions: 16

Compression:

Stored size: 433 Bytes

Contents

module Lookbook
  module ApplicationHelper
    def config
      Lookbook::Engine.config.lookbook
    end

    def feature_enabled?(name)
      Lookbook::Features.enabled?(name)
    end

    def landing_path
      landing = feature_enabled?(:pages) ? Lookbook.pages.find(&:landing) || Lookbook.pages.first : nil
      if landing.present?
        page_path(landing.lookup_path)
      else
        home_path
      end
    end
  end
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
lookbook-0.8.3 app/helpers/lookbook/application_helper.rb
lookbook-0.8.2 app/helpers/lookbook/application_helper.rb
lookbook-0.8.1 app/helpers/lookbook/application_helper.rb
lookbook-0.8.0 app/helpers/lookbook/application_helper.rb
lookbook-0.8.0.beta.0 app/helpers/lookbook/application_helper.rb
lookbook-0.7.4 app/helpers/lookbook/application_helper.rb
lookbook-0.7.3 app/helpers/lookbook/application_helper.rb
lookbook-0.7.2 app/helpers/lookbook/application_helper.rb
lookbook-0.7.2.beta.5 app/helpers/lookbook/application_helper.rb
lookbook-0.7.2.beta.4 app/helpers/lookbook/application_helper.rb
lookbook-0.7.2.beta.3 app/helpers/lookbook/application_helper.rb
lookbook-0.7.2.beta.2 app/helpers/lookbook/application_helper.rb
lookbook-0.7.2.beta.1 app/helpers/lookbook/application_helper.rb
lookbook-0.7.2.beta.0 app/helpers/lookbook/application_helper.rb
lookbook-0.7.1 app/helpers/lookbook/application_helper.rb
lookbook-0.7.0 app/helpers/lookbook/application_helper.rb