Classes and functions for handling debugging
The best way to use this package is through Composer:
composer require italystrap/debug
Simply add the below code into your wp-config.php file
<?php
define( 'WP_DEBUG', true ); // Load helpers for debugging
define( 'WP_DEBUG_LOG', true ); // Write to debug.log file
define( 'WP_DEBUG_DISPLAY', false ); // Optional
@ini_set( 'display_errors', 0 ); // Optional
define( 'SCRIPT_DEBUG', true );
define( 'SAVEQUERIES', true );
define( 'ITALYSTRAP_DEBUG', true ); // Load helpers for debugging
Now you can use:
<?php
d();
debug( $log );
For handling php errors it will be use Whoops that will display a screen with the full stack of information about the error.
TODO
All feedback / bug reports / pull requests are welcome.
Copyright (c) 2019 Enea Overclokk, ItalyStrap
This code is licensed under the MIT.
TODO