I would like you to help me with this problem.
I have some time working with a project in Laravel 5.6. This week I installed the barryvdh / laravel-dompdf package via composer as indicated in the documentation. I added the respective service provider in the config \ app.php file.
When trying to use the package for the first time I get the following error in Chrome: "An error occurred while loading the PDF document"
When I download the document and visualize it with a text editor, I realize that the only thing that is wrong with the file is that it lacks the first line:% PDF-1.3. When adding said line manually the document is "fixed".
To continue testing, I installed a new laravel project, and then I installed the package and created a route with the same code from the previous project. To my surprise, this project does load the PDF document in Chrome.
Please give me some idea of what things I can review.
Thank you very much