nin/phalcon-debugbar
最新稳定版本:v1.0.0
Composer 安装命令:
composer require nin/phalcon-debugbar
包简介
Integrates PHP Debug Bar with Phalcon 5.
README 文档
README
This is a package to integrate PHP Debug Bar with Phalcon 5.
Note: Use the DebugBar only in development. It can slow the application down (because it has to gather data). So when experiencing slowness, try disabling some of the collectors.
Installation:
Require this package with composer. It is recommended to only require the package for development.
composer require nin/phalcon-debugbar --dev
Register a Provider in index.php
$container = new \Phalcon\Di\FactoryDefault(); $container->register(new \Nin\Debugbar\ServiceProvider());
Usage:
Add Message
use Nin\Debugbar\Phalcon\Helper\Debugbar; Debugbar::info($object); Debugbar::error('Error!'); Debugbar::warning(new \Phalcon\Config\Config(['title' => 'Warning']));
Add start/stop timing:
use Nin\Debugbar\Phalcon\Helper\Debugbar; Debugbar::startMeasure('function', 'Function runtime'); Debugbar::stopMeasure('function'); Debugbar::measure('function', function() { // Do something… });
Add Log Exception:
use Nin\Debugbar\Phalcon\Helper\Debugbar; try { // Do something } catch (Exception $e) { Debugbar::addThrowable($e); }
统计信息
- 总下载量: 66
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 2
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2023-02-12