reactdatagrid
reactdatagrid copied to clipboard
editorProps does not exist in Column Definition
- what edition are you using - community
- version for
@inovua/reactdatagrid-community4.8.1
Relevant code or config
import '@inovua/reactdatagrid-enterprise/index.css';
import React, { useCallback, useState } from 'react';
import BoolEditor from '@inovua/reactdatagrid-community/BoolEditor';
import NumericEditor from '@inovua/reactdatagrid-community/NumericEditor';
import ReactDataGrid from '@inovua/reactdatagrid-enterprise';
import { TypeColumn } from '@inovua/reactdatagrid-community/types';
const gridStyle = { minHeight: 550 };
const App = () => {
const [dataSource, setDataSource] = useState([]);
const columns: TypeColumn[] = [
{ name: 'id', header: 'Id', defaultVisible: false, type: 'number' },
{ name: 'name', defaultFlex: 1, minWidth: 200, maxWidth: 300, header: 'Name' },
{
name: 'student',
header: 'Student',
width: 100,
editor: BoolEditor,
render: ({ value }) => (value ? 'Yes' : 'No'),
editorProps: {
style: { background: 'rgba(121, 134, 203, 0.25)' },
},
},
];
return (
<div>
<ReactDataGrid
idProperty="id"
style={gridStyle}
editable={true}
columns={columns}
dataSource={dataSource}
/>
</div>
);
};
export default () => <App />;
I was trying to create a simple BoolEditor editor column as documented in https://reactdatagrid.io/docs/api-reference#props-columns-editorProps there should be a editorProps property on the column definition, but it seems that is not the case
I also checked the typeDefinitions at TypeColumn.d.ts file, its not there

is the documentation outdated or am I missing something ? thanks for your time