Yes, many of us avoid debuggers like the plague and clamp on to our puts statements like an umbrella in a stormy day. Why not make it official and have puts debugging become its own perfectly legitimate thing?!!
And thus, puts_debuggerer was born. A guilt-free puts debugger Ruby gem FTW!
In other words, puts_debuggerer is a Ruby library for improved puts debugging, automatically displaying bonus useful information such as source line number and source code.
Options enable more data to be displayed with puts_debuggerer, such as the caller backtrace, header, and footer. They also allow customization of output format.
(default = :p)
Print engine to use in object printout (e.g. p, ap, pp). It is represented by the print engine's global method name as a symbol (e.g. :ap forawesome_print). Defaults to Ruby's built-in p method identified by the symbol :p. If it findsawesome_printloaded, it defaults to ap as :ap instead.
Formatter used in every print out Passed a data argument with the following keys:
NOTE: data for :object_printer is not a string, yet a proc that must be called to output value. It is a proc as it automatically handles usage of print_engine and encapsulates its details. In any case, data for :object is available should one want to avoid altogether.