Sha256: 29f72b36e755982399cae9271b982f2fc3fa7ca6bbbff6fce0a9bdf9f8ec15ad

Contents?: true

Size: 518 Bytes

Versions: 3

Compression:

Stored size: 518 Bytes

Contents

module PageHelper
  def title(page_title)
    content_for(:title) { page_title.to_s + " | Application Name" }
  end
  
  def page_name(name)
    content_for(:page_name) { name.to_s }
  end
  
  def meta_desc(desc)
    content_for(:meta_desc) { desc.to_s }
  end
  
  def meta_keywords(desc)
    content_for(:meta_keywords) { desc.to_s }
  end
  
  def sidebar(content)
    content_for(:sidebar) { content.to_s }
  end  
  
  def nav_link(page)
    link_to page.titleize, page_path(page.downcase), :id => page
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
creature-0.0.6 lib/generators/pages/templates/page_helper.rb
creature-0.0.5 lib/generators/pages/templates/page_helper.rb
creature-0.0.4 lib/generators/pages/templates/page_helper.rb