Skip to content

coder-packages/laravel-profile-json-response

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Profiling JSON responses in Laravel

Setup

Set middleware in middle property in App\Http\Kernel

<?php

namespace App\Http;

use Illuminate\Foundation\Http\Kernel as HttpKernel;

class Kernel extends HttpKernel
{
    protected $middleware = [
        \Larapackages\ProfileJsonResponse\Middleware\ProfileJsonResponse::class
    ];
}

Set profile param in request for getting debug info in json response

For limitation profiling data output, set $profilingData property keys

protected $profilingData = ['queries'];