canducci / laravel-dompdf-helpers
Helper Laravek DomPdf
v0.1.0
2021-04-23 16:21 UTC
Requires
- php: ^7.2 || ^8.0
- barryvdh/laravel-dompdf: ^0.9.0
Requires (Dev)
- phpspec/phpspec: 7.0.1
- phpunit/phpunit: 9.5.4
This package is auto-updated.
Last update: 2024-10-16 22:08:27 UTC
README
Installation
First go to the website barryvdh/laravel-dompdf and configure the package before this installation. Then do these procedures:
composer require canducci/laravel-dompdf-helpers
Use Helpers
$instance = printer(); $instance->loadView($view, $data); $instance->download(); // or $instance->stream();
Report View Laravel blade
Example 1
$instance = printer_view($view, $data); $instance->stream(); // or $instance->download();
Example 2
return printer_view_stream($view, $data); // or printer_view_download($view, $data);
Report File
Example 1
$instance = printer_file($path); $instance->stream(); // or $instance->download();
Example 2
return printer_file_stream($path); // or printer_file_download($path);
Report HTML
Example 1
$instance = printer_html($path); $instance->stream(); // or $instance->download();
Example 2
return printer_html_stream($path); // or printer_html_download($path);