In the controller you can:
render :text => @some_object.inspect
But your view won’t be rendered.
You could also:
Rails.logger.debug("My object: #{@some_object.inspect}")
and run tail on log/development.log to see the output.
In the view the recommeneded way is:
<%= debug(@some_object) %>