Module: PublicHelper

Defined in:
lib/generators/datalab/layout/templates/public_helper.rb

Instance Method Summary collapse

Instance Method Details

#javascript(*args) ⇒ Object



15
16
17
# File 'lib/generators/datalab/layout/templates/public_helper.rb', line 15

def javascript(*args)
  content_for(:head) { javascript_include_tag(*args) }
end

#show_title?Boolean

Returns:

  • (Boolean)


7
8
9
# File 'lib/generators/datalab/layout/templates/public_helper.rb', line 7

def show_title?
  @show_title
end

#stylesheet(*args) ⇒ Object



11
12
13
# File 'lib/generators/datalab/layout/templates/public_helper.rb', line 11

def stylesheet(*args)
  content_for(:head) { stylesheet_link_tag(*args) }
end

#title(page_title, show_title = true) ⇒ Object



2
3
4
5
# File 'lib/generators/datalab/layout/templates/public_helper.rb', line 2

def title(page_title, show_title = true)
  content_for(:title) { h(page_title.to_s) }
  @show_title = show_title
end