composer require barryvdh/laravel-debugbar --dev
php artisan vendor:publish --provider="BarryvdhDebugbarServiceProvider"
'debug' => env('APP_DEBUG', false),
BarryvdhDebugbarServiceProvider::class,
php artisan vendor:publish --provider="BarryvdhDebugbarServiceProvider"
$app->configure('debugbar');
if (env('APP_DEBUG')) {
$app->register(BarryvdhDebugbarLumenServiceProvider::class);
}
'Debugbar' => BarryvdhDebugbarFacade::class,
Debugbar::startMeasure('render','Time for rendering');
Debugbar::stopMeasure('render');
Debugbar::addMeasure('now', LARAVEL_START, microtime(true));
Debugbar::measure('My long operation', function() {
// Do something…
});