Skip to content

Commit 173c116

Browse files
authored
fix: dataindex allow array (#1097)
* Update interface.ts fix dataindex array * fix: allow number type
1 parent 7afff24 commit 173c116

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/interface.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,9 +67,10 @@ export interface RenderedCell<RecordType> {
6767

6868
export type Direction = 'ltr' | 'rtl';
6969

70+
// SpecialString will be removed in antd@6
7071
export type SpecialString<T> = T | (string & {});
7172

72-
export type DataIndex<T = any> = DeepNamePath<T> | SpecialString<T>;
73+
export type DataIndex<T = any> = DeepNamePath<T> | SpecialString<T> | number | (SpecialString<T> | number)[];
7374

7475
export type CellEllipsisType = { showTitle?: boolean } | boolean;
7576

0 commit comments

Comments
 (0)