render(view, locals, buffer=nil, &block)public
Render a template. If the template was not compiled yet, it is done exactly before rendering.
This method is instrumented as “!render_template.action_view”. Notice that we use a bang in this instrumentation because you don’t want to consume this in production. This is only slow if it’s being listened to.
# File actionview/lib/action_view/template.rb, line 142 def render(view, locals, buffer=nil, &block) instrument("!render_template") do compile!(view) view.send(method_name, locals, buffer, &block) end rescue => e handle_render_error(view, e) end