Class: Sinatra::ContentFor2::HamlHandler
Instance Attribute Summary
Attributes inherited from BaseHandler
#template
Instance Method Summary
collapse
Methods inherited from BaseHandler
classes, #initialize, register
Instance Method Details
#block_is_type?(block) ⇒ Boolean
6
7
8
|
# File 'lib/sinatra/content_for2/haml_handler.rb', line 6
def block_is_type?(block)
template.block_is_haml?(block)
end
|
#capture_from_template(*args, &block) ⇒ Object
10
11
12
13
|
# File 'lib/sinatra/content_for2/haml_handler.rb', line 10
def capture_from_template(*args, &block)
eval("_hamlout ||= @haml_buffer", block.binding) template.capture_haml(*args, &block)
end
|
#engines ⇒ Object
15
16
17
|
# File 'lib/sinatra/content_for2/haml_handler.rb', line 15
def engines
@engines ||= [ :haml ]
end
|
#is_type? ⇒ Boolean
2
3
4
|
# File 'lib/sinatra/content_for2/haml_handler.rb', line 2
def is_type?
template.respond_to?(:is_haml?) && template.is_haml?
end
|