How can I initially hide the "Show/Hide columns" button in material-react-table?
I searched through the documentation but couldn't find any information on how to hide this button.
Thanks in advance.
How can I initially hide the "Show/Hide columns" button in material-react-table?
I searched through the documentation but couldn't find any information on how to hide this button.
Thanks in advance.
On
You can hide all of the default toolbar buttons using these settings.
enableHiding: false,
enableGlobalFilter: false,
enableFullScreenToggle: false,
enableDensityToggle: false,
enableFilters: false
The docs don't cover these settings unfortunately, if you choose to hide the toolbar entirely you will lose access to certain features such as the top of table progress bar.
You can remove the column hiding button from the top toolbar by setting the
enableHidingprop tofalsein Material React Table.Example:
Result:
Working CodeSandbox: https://codesandbox.io/p/sandbox/dreamy-browser-s8893s?file=%2Fsrc%2FTS.tsx%3A106%2C36