| Module | ActionController::Components::InstanceMethods |
| In: |
vendor/rails/actionpack/lib/action_controller/components.rb
|
Renders the component specified as the response for the current method
# File vendor/rails/actionpack/lib/action_controller/components.rb, line 81
81: def render_component(options) #:doc:
82: component_logging(options) do
83: render_for_text(component_response(options, true).body, response.headers["Status"])
84: end
85: end
Returns the component response as a string
# File vendor/rails/actionpack/lib/action_controller/components.rb, line 89
89: def render_component_as_string(options) #:doc:
90: component_logging(options) do
91: response = component_response(options, false)
92:
93: if redirected = response.redirected_to
94: render_component_as_string(redirected)
95: else
96: response.body
97: end
98: end
99: end