fs-public / ib-analyzer

MIT License
0 stars 0 forks source link

PDF export pagebreaks #21

Open fs-public opened 1 year ago

fs-public commented 1 year ago

PhantomJS does not respect 'page-break-after: always' within tables, see discussions:

https://github.com/marcbachmann/node-html-pdf/issues/223 https://github.com/ariya/phantomjs/issues/13524

Closest fix (works in early rows, but extends late rows): https://github.com/ariya/phantomjs/issues/10638#issuecomment-20186253

Not only that, pages with same spacing are sometimes rendered differently (not pixel-perfect). This all boils down to slower maintenance and recent deprecation of PhantomJS.

Note that the page-break attribute works well when opening handlebar-rendered HTML in Chrome and hitting Print.

Possible solutions:

Issue is non-critical as no content is lost/hidden in the resulting PDF, worst case it is split between two pages.