Add more documentation for overriding props (#975)

I think this is the most common way of setting columns or expanderDefaults.

I had to find issue #565 and then follow it to issue #394 to see explanations on how to do this.
This commit is contained in:
Mark McDonald
2018-05-24 18:35:22 -04:00
committed by Tanner Linsley
parent cf59c644b4
commit 1f92ed8d4f

View File

@@ -294,6 +294,8 @@ These are all of the available props (and their default values) for the main `<R
getResizerProps: () => ({}),
// Global Column Defaults
// To override only some values, import { ReactTableDefaults } from 'react-table'
// and construct your overrides (e.g. {...ReactTableDefaults.column, className: 'react-table-cell'})
column: {
// Renderers
Cell: undefined,
@@ -329,6 +331,8 @@ These are all of the available props (and their default values) for the main `<R
},
// Global Expander Column Defaults
// To override only some values, import { ReactTableDefaults } from 'react-table'
// and construct your overrides (e.g. {...ReactTableDefaults.expanderDefaults, sortable: true})
expanderDefaults: {
sortable: false,
resizable: false,