mirror of
https://gitee.com/ant-design/ant-design.git
synced 2024-12-05 05:28:20 +08:00
857ee24e38
* type: Table TypeScript improvement * type: Table TypeScript improvement * type: Table TypeScript improvement * fix: fix demo * fix: fix demo * fix: fix type * fix: fix type * fix: fix type * fix: fix type
16 lines
565 B
TypeScript
16 lines
565 B
TypeScript
import { genVirtualTable } from 'rc-table';
|
|
|
|
import type { AnyObject } from '../../_util/type';
|
|
import type { InternalTableProps } from '../InternalTable';
|
|
|
|
/**
|
|
* Same as `rc-table` but we modify trigger children update logic instead.
|
|
*/
|
|
const RcVirtualTable = genVirtualTable((prev, next) => {
|
|
const { _renderTimes: prevRenderTimes } = prev as Readonly<InternalTableProps<AnyObject>>;
|
|
const { _renderTimes: nextRenderTimes } = next as Readonly<InternalTableProps<AnyObject>>;
|
|
return prevRenderTimes !== nextRenderTimes;
|
|
});
|
|
|
|
export default RcVirtualTable;
|