2

I have a project with Laravel version 7.28. I run

composer require barryvdh/laravel-debugbar --dev, 

After that I added Barryvdh\Debugbar\ServiceProvider::class to app/config.php under providers and added

'Debugbar' => Barryvdh\Debugbar\Facade::class

to app/config.php under aliases. Then I run

php artisan vendor:publish --provider="Barryvdh\Debugbar\ServiceProvider"

Even though APP_DEBUG in .env is true and I terminated and rerun the app debugbar is not showing. Where did I make my mistake?

John Conde
  • 217,595
  • 99
  • 455
  • 496
jigsaw075
  • 155
  • 2
  • 16

2 Answers2

1

I checked the config/debugbar.php, I see the new key DEBUGBAR_ENABLED with default is false. Then add it to .env file: DEBUGBAR_ENABLED=true

Nhat Ngo
  • 113
  • 2
  • 9
0

Make sure you are running on right port. I had php backend (running on port 8000) and react frontend (running on port 3000) and I did everything you have described above but it never worked. The issue I had was that I was checking if the debugbar showed up on port 3000 (which it never did sadly). I went to check on port 8000 and the debugbar was sitting there the whole time.

I didn't end up using the php debugbar because I think it only works if your frontend code is written in php (though not 100% sure).

I ended up debugging using postman. It doesn't have all the functionalities that the debugbar offers but it is a great tool to use if you just want to do basic debugging.

rgb123
  • 1
  • 1