I've searched through past issues and it seems it was experienced a lot by people. But I was not able to find any clear solution that worked in my case.
Here I create a simple stackblitz reproduction:
https://stackblitz.com/edit/angular-d9narm
I expect the table to fit the parent's content area and show the scrollbar when its needed. This also should work properly when the parent is resized.
It is such a basic scenario and still I cannot find a clear solution... Can anybody give me a hand?
So, in case somebody cares, i was able to concuct a solution: https://stackblitz.com/edit/primeng-scrollable-table-fit-parent This seems to work as expected when the windows is resized horizontally.
I've also used a hack inspired by this sample: https://stackblitz.com/edit/primeng-dynamic-scrollable in order to work-around another bug: header cells becoming misaligned.
It would be really nice if all this hacking was not needed and stuff just worked, so maybe this could be somehow incorporated into the next release, @cagataycivici?
Unable to replicate with PrimeNG 9, if the issue persists please create a new ticket with a test case reproducing the issue e.g. stackblitz or a github repo and it will be reviewed by our team once again.
Most helpful comment
So, in case somebody cares, i was able to concuct a solution: https://stackblitz.com/edit/primeng-scrollable-table-fit-parent This seems to work as expected when the windows is resized horizontally.
I've also used a hack inspired by this sample: https://stackblitz.com/edit/primeng-dynamic-scrollable in order to work-around another bug: header cells becoming misaligned.
It would be really nice if all this hacking was not needed and stuff just worked, so maybe this could be somehow incorporated into the next release, @cagataycivici?