vue-html2pdf-demo
vue-html2pdf-demo copied to clipboard
Getting different results when downloading PDF
I used the VueHTML2PDF library to generate a PDF from an existing Vue js component but, the behavior of the generated document is not stable from one pc to another and on the same pc also even with the same data . Page breaks are not handled well with a large table.
Here is how I used the library and the results obtained:
<vue-html2pdf
:float-layout="true"
:enable-download="true"
:show-layout="false"
:paginate-elements-by-height="1400"
filename="test"
:pdf-quality="2"
:manual-pagination="false"
pdf-format="a4"
pdf-orientation="portrait"
pdf-content-width="800px"
:ref="'pdfDeposit' + index"
>
<section slot="pdf-content">
<section class="pdf-item">
<DepositReport :id="item.id"></DepositReport>
</section>
<div class="html2pdf__page-break"/>
<section class="pdf-item"></section>
</section>
</vue-html2pdf>