You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+34-2Lines changed: 34 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -617,9 +617,41 @@ See the [Dompdf font guide](https://github.com/dompdf/dompdf).
617
617
618
618
## Customizing the Template
619
619
620
-
To customize the invoice template, you can publish the provided views and modify them as needed.
620
+
To customize the invoice template, first publish the views using:
621
621
622
-
Alternatively, you can create a completely custom template. Ensure that your custom template follows the same structure and conventions as the default one to maintain compatibility with various use cases.
622
+
```bash
623
+
php artisan vendor:publish --tag="invoices-views"
624
+
```
625
+
626
+
Then modify the blade files to your liking.
627
+
628
+
Alternatively, you can create a completely custom template by editing the config file like this:
629
+
630
+
```php
631
+
return [
632
+
633
+
// ...
634
+
635
+
'pdf' => [
636
+
637
+
/**
638
+
* The template used to render the PDF
639
+
*/
640
+
'template' => 'default.layout',
641
+
642
+
'template_data' => [
643
+
/**
644
+
* The color displayed at the top of the PDF
645
+
*/
646
+
'color' => '#050038',
647
+
],
648
+
649
+
],
650
+
651
+
];
652
+
```
653
+
654
+
Ensure that your custom template follows the same structure and conventions as the default one to maintain compatibility with various use cases.
0 commit comments