pollen-solutions / debug
Pollen Solutions - Debug Component - Collection of debugging tools.
Installs: 464
Dependents: 2
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 0
Open Issues: 0
Type:presstify-component
Requires
- php: ^7.4 || ^8.0
- filp/whoops: ^2.9
- maximebf/debugbar: ^1.16
- pollen-solutions/event: ^1.0
- pollen-solutions/http: ^1.0
- pollen-solutions/routing: ^1.0
- pollen-solutions/support: ^1.0
- symfony/error-handler: ^5.2
- symfony/var-dumper: ^5.2
Requires (Dev)
- phpunit/phpunit: ^9.0
- roave/security-advisories: dev-latest
Suggests
- pollen-solutions/asset: Pollen Solutions - Asset Component - Tools to manage assets in web applications.
- pollen-solutions/container: Pollen Solutions - Container Component - PSR-11 ready Dependencies Injection Container.
This package is auto-updated.
Last update: 2024-10-30 02:10:43 UTC
README
Pollen Solutions Debug Component provides a collection of tools dedicated to debugging.
Installation
composer require pollen-solutions/debug
Basic Usage
ErrorHandler
use Pollen\Debug\DebugManager; // DebugManager instantiation $debug = new DebugManager(); // ErrorHandler activation $debug->errorHandler()->enable(); // ErrorHandler test function errorHandlerTest() { throw new InvalidArgumentException('Test de Whoops'); } errorHandlerTest();
DebugBar
use Pollen\Debug\DebugManager; // DebugManager instantiation $debug = new DebugManager(); // DebugBar activation $debug->debugBar()->enable(); // DebugBar test echo <<< HTML <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>Debug Bar Test</title> HTML; // DebugBar head assets echo $debug->debugBar()->renderHead(); echo <<< HTML </head> <body> HTML; // DebugBar render echo $debug->debugBar()->render(); echo <<< HTML </body> </html> HTML; exit;