Skip to content

Instantly share code, notes, and snippets.

@Parables
Last active October 27, 2021 05:37
Show Gist options
  • Select an option

  • Save Parables/39eb3af72ded9aec9b8562ffb454d100 to your computer and use it in GitHub Desktop.

Select an option

Save Parables/39eb3af72ded9aec9b8562ffb454d100 to your computer and use it in GitHub Desktop.
BrowserConsole.php
<?php
namespace App\Http\Middleware;
use Closure;
use Illuminate\Http\Request;
use Monolog\Handler\BrowserConsoleHandler;
class BrowserConsole
{
/**
* Handle an incoming request.
*
* @param \Illuminate\Http\Request $request
* @param \Closure $next
* @return mixed
*/
public function handle(Request $request, Closure $next)
{
$response = $next($request);
BrowserConsoleHandler::class;
return $response;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment