Wicked_pdf: Provide Page Breaks

Created on 29 Apr 2016  路  2Comments  路  Source: mileszs/wicked_pdf

Hello,
I wonder if it is possible to give page breaks within the html code?

Most helpful comment

You can by applying CSS to elements like this:

div.alwaysbreak { page-break-before: always; }
div.nobreak:before { clear:both; }
div.nobreak { page-break-inside: avoid; }

Or like this:

<div style="page-break-after: always;"></div>

I'm surprised I've never added anything about this to the README before now, and your question has inspired me to add it!
https://github.com/mileszs/wicked_pdf#page-breaks

Let me know if you have any further questions or issues!

All 2 comments

You can by applying CSS to elements like this:

div.alwaysbreak { page-break-before: always; }
div.nobreak:before { clear:both; }
div.nobreak { page-break-inside: avoid; }

Or like this:

<div style="page-break-after: always;"></div>

I'm surprised I've never added anything about this to the README before now, and your question has inspired me to add it!
https://github.com/mileszs/wicked_pdf#page-breaks

Let me know if you have any further questions or issues!

Thank you very much for your help and I am really sorry for the delayed response.

~ Cheers!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

andheiberg picture andheiberg  路  3Comments

amerritt14 picture amerritt14  路  4Comments

gregblass picture gregblass  路  4Comments

panniru picture panniru  路  5Comments

thomasbalsloev picture thomasbalsloev  路  3Comments