instance method
view_context_class
Ruby on Rails 4.0.13
Since v3.0.20 Last seen in v4.0.13Signature
view_context_class()
No documentation comment.
Source
# File actionpack/lib/abstract_controller/rendering.rb, line 50
def view_context_class
@view_context_class ||= begin
routes = respond_to?(:_routes) && _routes
helpers = respond_to?(:_helpers) && _helpers
Class.new(ActionView::Base) do
if routes
include routes.url_helpers
include routes.mounted_helpers
end
if helpers
include helpers
end
end
end
end
Defined in actionpack/lib/abstract_controller/rendering.rb line 50
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in AbstractController::Rendering::ClassMethods