PHP debugging tools

4.0.0 2022-08-20 19:00 UTC


Debugging tools for PHP

Scrutinizer Code Quality Scrutinizer Code Coverage Scrutinizer Build Status

Packagist Latest Stable Version Packagist Total Downloads


The recommended way to install is through Composer:

composer require xicrow/php-debug:~4.0


composer require --dev xicrow/php-debug:~4.0

Optionally add it to your composer.json file:

	"require": {
		"xicrow/php-debug": "~4.0"


	"require-dev": {
		"xicrow/php-debug": "~4.0"


See examples in the demo folder.

View the seperate readme for:


  • Debug functions for displaying variable information, pr(), vd(), etc.
    Implemented, available in Debugger class
  • Collection class for Timer::$timers, and maybe others
    Implemented, available in Collection class
    Removed, too memory hungry
  • Memory class for measuring memory usage
    Implemented, available in Memory class
    Removed, too unreliable
  • Improve Timer and Memory, perhaps a Profiler class
    Implemented, available in Profiler class
    Removed, along with Memory
  • Add PHPunit tests
    Implemented, now remeber to keep them updated
  • Improve Debugger, foldable tree of arrays/objects
    Skipped, not sensible to do, clutter with either HTML or JS/CSS
  • Groupable timers, timers with the same name will be grouped and min, max and average will be calculated (activate when stopping a timer)
  • Update example demo output in Debugger and Timer README
  • Update to PHP 7.4 Done Implemented type declarations, return types, etc. Implemented type prefixed variables
  • Change option arrays to explicit variables or option classes Fixed in most places, just need the rest


Copyright © 2018 Jan Ebsen Licensed under the MIT license.