primereact
primereact copied to clipboard
Datatables not working with scrollHeight as 100%
There is no guarantee in receiving an immediate response in GitHub Issue Tracker, If you'd like to secure our response, you may consider PrimeReact PRO Support where support is provided within 4 business hours
I'm submitting a ... (check one with "x")
[x] bug report
[ ] feature request
[ ] support request => Please do not submit support request here, instead see https://forum.primefaces.org/viewforum.php?f=57
Codesandbox Case (Bug Reports) https://codesandbox.io/s/trusting-cdn-tr5hy?file=/src/demo/DataTableBasicDemo.js
Current behavior If you want have a datatable with Expected behavior
Minimal reproduction of the problem with instructions
If you want to use a grid datatable with the scrollable active that completely occupies the height of the parent div, when setting scrollHeight attribute as 100%, the component has fixed height.
Please tell us about your environment:
Windows 10
- React version:
React 16.13.0
- PrimeReact version:
Primeface 5.0.0
- Browser: [all | Chrome XX | Firefox XX | IE XX | Safari XX | Mobile Chrome XX | Android X.X Web Browser | iOS XX Safari | iOS XX UIWebView | iOS XX WKWebView ]
Chrome 85
- Language: [all | TypeScript X.X | ES6/7 | ES5] ES6
You can use flex scroll;
<DataTable scrollHeight="flex" ...>