定制 jaguarsoft/laravel-debugbar 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

jaguarsoft/laravel-debugbar

最新稳定版本:5.2.0

Composer 安装命令:

composer require jaguarsoft/laravel-debugbar

包简介

Handle Debugbar Enabling by Middleware

README 文档

README

This package allows you to enable the Debugbar on deman, despite being disabled by configuration.

Installation

composer require jaguarsoft/laravel-debugbar

Configuration

config/app.php

'providers' => [   
    /** **/ 
    // Barryvdh\Debugbar\ServiceProvider::class,
    JaguarSoft\LaravelDebugbar\Provider\DebugbarServiceProvider::class,
],
'aliases' => [
    /** **/
    'Debugbar' => Barryvdh\Debugbar\Facade::class,
],

Use

To load Enabled for All

DEBUGBAR_ENABLED=true

To load Disable for All, enabled after in a Middleware

DEBUGBAR_ENABLED=false

To load Enabled when APP_DEBUG=true

DEBUGBAR_ENABLED=null

Middleware

public function handle($request, Closure $next){
    if(/* your validation*/){
        \Debugbar::enable();
    }
    return $next($request);
}

Example Middleware: https://gist.github.com/laurenceHR/911050c675eb5a1d28b761b61b3b25a0

Used and Tested in Laravel 5.2, 5.3, 5.4 Is not necessary in Laravel 5.5 because with "barryvdh/laravel-debugbar" version "~3.4.2" has this feature included.

统计信息

  • 总下载量: 417
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2022-05-07