How to set page break in dynamic content rotativa ?
I have a list of lists which loads data dynamically through a model binding
@foreach (var item in Model.Items)
{
<div class="separator-bottom col-xs-12 avoid-page-break">
<div>
(generates the list)
</div>
</div>
}
And my avoid-page-break
class is like this
.avoid-page-break {
page-break-inside: avoid !important;
margin: 4px 0 4px 0
}
I followed, this answer. I've used the styling as mentioned in it. It solves the issue in 1st page, but still having the issue from 2nd page onwards.
Is there any workaround to solve this ? Any help would be appreciated. Thanks