Sha256: 538c74f3462235da4dfd365358dceee096dd4a3c9b99b5036d34cc7b8f464d8d

Contents?: true

Size: 397 Bytes

Versions: 9

Compression:

Stored size: 397 Bytes

Contents

module PageTitleHelper
  def page_title(options = {})
    app_name = options[:app_name] || Rails.application.class.to_s.split('::').first
    page_title_symbol = options[:page_title_symbol] || :page_title
    separator = options[:separator] || ' : '

    if content_for?(page_title_symbol)
      [app_name, content_for(page_title_symbol)].join(separator)
    else
      app_name
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
flutie-2.0.0 lib/flutie/page_title_helper.rb
flutie-1.3.4 app/helpers/page_title_helper.rb
flutie-1.3.3 app/helpers/page_title_helper.rb
flutie-1.3.2 app/helpers/page_title_helper.rb
flutie-1.3.1 app/helpers/page_title_helper.rb
flutie-1.3.0 app/helpers/page_title_helper.rb
flutie-1.2.5 app/helpers/page_title_helper.rb
flutie-1.2.4 app/helpers/page_title_helper.rb
flutie-1.2.3 app/helpers/page_title_helper.rb