Class: ApplicationController
- Inherits:
-
ActionController::Base
- Object
- ActionController::Base
- ApplicationController
- Defined in:
- app/controllers/application_controller.rb
Direct Known Subclasses
Instance Method Summary collapse
-
#view_context ⇒ Object
Cache to use ‘view_context.content_for` from controller.
Instance Method Details
#view_context ⇒ Object
Cache to use ‘view_context.content_for` from controller. This hack is nice to hook view_context from a plugin.
Examples
JobsController.before_filter do
view_context.content_for :jobs_show, "This is a footer."
end
21 22 23 |
# File 'app/controllers/application_controller.rb', line 21 def view_context @view_context ||= super end |