I had the same problem, after I searched for it without any results, I decided to play with the code, and it worked for me.
Inside config / app.php
-> under the providers add a line of code,
'Barryvdh\DomPDF\ServiceProvider' not Barryvdh\DomPDF\ServiceProvider::class,

-> under the aliases add a line of code,
'PDF' => 'Barryvdh\DomPDF\Facade' not 'PDF' => Barryvdh\DomPDF\Facade::class,

Remember quotes and commas! Check out the images above
-> In your controller add a line of code, use the application;

Hope you can pass the test well ... using lines of code .. put them inside the method in your controller.
$pdf = App::make('dompdf.wrapper'); $pdf->loadHTML('<h1>Test</h1>'); return $pdf->stream();
If successful, your browser will open the PDF Viewer with a white PDF with the word Test
Hi, enjoy your coding;)
source share