2

I am using Chrome mostly, and maybe first time I found problem like this. It working in IE, not sure other browsers, but no in Chrome. Any idea or tips?

@media print
{
table {page-break-inside:avoid}
}

also when just puting into div element

Dudeist
  • 363
  • 1
  • 4
  • 13

3 Answers3

3

It could be that the parent element of the table element has style:

display: flex 

Then the break-inside doesn’t work.

If you change parent element display style to:

display: block

Then it will work.

Kristjan Retter
  • 411
  • 5
  • 11
1

Add display:inline-table to any element that you need to be entire when printing or, in your case to table element

table { display: inline-table;}

0

Chrome does not support that property. Look at this table for more infos on that.

Answer taken from this question

Community
  • 1
  • 1
Mike
  • 2,567
  • 3
  • 23
  • 35