Name
Dump::Krumo - Fancy, colorful, human readable dumps of your data
Synopsis
use Dump::Krumo;
my $data = { one => 1, two => 2, three => 3 };
kx($data);
my $list = ['one', 'two', 'three', 'four'];
kxd($list);
Description
Colorfully dump your data to make debugging variables easier. Dump::Krumo
focuses on making your data human readable and easily parseable.
Screenshots
Methods
-
kx($var)
Debug print
$var. -
kxd($var)
Debug print
$varanddie(). This outputs file and line information.
Options
-
$Dump::Krumo::use_color = 1Turn color on/off
-
$Dump::Krumo::return_string = 0Return a string instead of printing out
-
$Dump::Krumo::indent_spaces = 2Number of spaces to indent each level
-
$Dump::Krumo::disable = 0Disable all output from
Dump::Krumo. This allows you to leave all of your debug print statements in your code, and disable them at runtime as needed. -
$Dump::Krumo::promote_bool = 1Convert JSON::PP::Booleans to true/false instead of treating them as objects.
-
$Dump::Krumo::stack_trace = 0When
kxd()is called it will dump a full stack trace. -
$Dump::Krumo::COLORSReference to a hash of colors for each variable type. Update this and create your own color scheme.
See Also
Author
Scott Baker - https://www.perturb.org/