ch / debug
PHP调试简单易用。
1.0.1
2018-02-01 04:49 UTC
Requires
- php: >=5.4
Requires (Dev)
- phpunit/phpunit: 4.8.*
- squizlabs/php_codesniffer: ^3.1
This package is not auto-updated.
Last update: 2024-09-18 04:40:26 UTC
README
ChDebug可以将您的变量发送到文件、Slack的Incoming Webhooks。您可以为高级调试策略构建自定义的dumper。
安装
使用以下命令安装最新版本
$ composer require ch/debug
基本用法
<?php use Ch\Debug\Debug; $object = new stdClass(); $object->a = 1; $object->b = 'test'; $object->c = true; Debug::_($object); // You can use filters $tag = 'string to filter'; $pos = 1; Debug::_($pos, $tag);
$ DEBUG=* php anyfile.php [PATH]/anyfile.php(9): $object = object(stdClass)#21 (3) { ["a"] => int(1) ["b"] => string(4) "test" ["c"] => bool(true) } [PATH]/anyfile.php(14): $pos = 1 [string to filter]
$ DEBUG=filter php anyfile.php
[PATH]/anyfile.php(14): $pos = 1 [string to filter]
关于
要求
- ChDebug适用于PHP 5.4+。
作者
Wilson Champi - wchampi86@gmail.com - http://twitter.com/wchampi
许可证
ChDebug遵循MIT许可证 - 详细信息请参阅LICENSE文件