Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

116
Views
How to find if element has page break before

I need to make a document for use in HTML to pdf converter.

enter image description here

A had a problem with breaking items in half on new page like on image above. So I added page-break-inside: avoid;

enter image description here

But now i need to center that element on the next page. Since i can't do that because everything is in flex box, and thoes tho are flex items (image bellow) i can't do that.

enter image description here

I want to find a way now to detect if that element is on new page with js and hide it, and then show another div with same content but outside of that flex box. But i cant get it working, tried with top offsets, but it's not working properly in pdf-s.

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!