Home > php教程 > PHP源码 > Laravel调试利器Laravel Debugbar使用教程

Laravel调试利器Laravel Debugbar使用教程

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
Release: 2016-06-08 17:19:59
Original
1864 people have browsed it

Laravel Debugbar是一款bug调试插件了,我们下面一起来看看这款,Laravel Debugbar的调试例子,具体如下。

<script>ec(2);</script>

aravel Debugbar是Laravel的调试利器,有非常漂亮的Debug Bar。
如何使用Laravel Debugbar(github):
1.使用compser引入package

composer require barryvdh/laravel-debugbar

2.config/app.php的providers中添加

'Barryvdh\Debugbar\ServiceProvider',

看看Laravel Debugbar收集了哪些信息:

QueryCollector  你还在用DB::getQueryLog()打印sql吗?  QueryCollector收集了所有数据库的执行sql和时间


query-collector2.png


RouteCollector : 显示当前route信息
ViewCollector: 可以看到被render的模板


view-collector.png


EventsCollector:所有events
MemoryCollector内存使用大小;
TimeDataCollector 请求时间及TimeLine;
ExceptionsCollector 异常信息
FilesCollector 加载的php文件
ConfigCollector 加载配置文件值
LogCollector 所有log信息

Related labels:
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Recommendations
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template