ActionView::Helpers::DebugHelper
def debug(object)

Description

Converts an object to YAML and uses it as the content of a <pre class="debug_dump">.

Arguments

Changing a value updates the ERB and HTML.

Converted to YAML with to_yaml, escaped, and used as the content. Before that, it tries Marshal.dump; an object that cannot be dumped (an instance of an anonymous class, a proc, an object with singleton methods, etc.) is not converted to YAML, and a <code class="debug_dump"> with its inspect string as the content is returned instead.

ERB

Changes from the previous output: Added Removed Changed


          

HTML


          

Preview