Class: ActionView::TemplateHandlers::RJS
- Inherits:
-
ActionView::TemplateHandler
- Object
- ActionView::TemplateHandler
- ActionView::TemplateHandlers::RJS
- Defined in:
- lib/action_view/template_handlers/rjs.rb
Class Method Summary collapse
Instance Method Summary collapse
Methods inherited from ActionView::TemplateHandler
Constructor Details
This class inherits a constructor from ActionView::TemplateHandler
Class Method Details
.line_offset ⇒ Object
4 5 6 |
# File 'lib/action_view/template_handlers/rjs.rb', line 4 def self.line_offset 2 end |
Instance Method Details
#compile(template) ⇒ Object
8 9 10 11 |
# File 'lib/action_view/template_handlers/rjs.rb', line 8 def compile(template) "controller.response.content_type ||= Mime::JS\n" + "update_page do |page|\n#{template}\nend" end |