jasonday / printThis

jQuery printing plugin; print specific elements on a page

Home Page:https://jasonday.github.io/printThis/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Printable Area

craigbass76 opened this issue · comments

I'm not sure how to define page margins reliably, mostly top and bottom where content runs across a page break. When I'm using pandoc/weasyprint to make HTML and PDFs, I've specified a <div class="pb">, and styled it { page-break-before: always; }, but Weasyprint took care of actual paper margins for me. I'm not sure how to do the same thing with printThis, or even if I can.

pageBreak

Are there some good working examples out in the wild to look at?

There's not a lot of reliability, but you can try to use the @page directive.

i.e. -

 @page {
        size: A4;
        margin: 0 !important;
    }