Examples › Pinning the first column
fix, fixed, affix, stickyWhen a table has many columns and needs to scroll horizontally, you may want to make sure its first column is always visible — for instance, to keep the record name or the row actions in view at all times.
You can achieve this by setting the pinFirstColumn DataTable prop to true:
Here is the code:
You can also combine this feature with records selection, in which case both the selection checkbox column and the first user-provided column will be pinned to the left side of the table:
Here is the code:
You can also use records selection and pin both the first and the last column at the same time:
Here is the code:
Using with column grouping
Here is an example of how you can pin the first column when using column grouping. Notice how the first group contains only one column, and how we’re using an absolutely positioned custom title component to create the illusion that the Name title is centered vertically:
Here is the code:














