ant-design/components/table/RcTable/VirtualTable.tsx
二货爱吃白萝卜 6f2bddd5a1
feat: Table support virtual (#44349)
* chore: update demo

* chore: adjust fixed style

* chore: opt scroll height

* chore: clean up

* chore: update demo

* chore: bump rc-virtual-list

* chore: update deps

* chore: bump rc-table

* fix: clean up

* chore: fix demo

* test: add test case
2023-08-28 17:36:23 +08:00

13 lines
442 B
TypeScript

import { genVirtualTable } from 'rc-table';
import type { InternalTableProps } from '../InternalTable';
/**
* Same as `rc-table` but we modify trigger children update logic instead.
*/
export default genVirtualTable((prev, next) => {
const { _renderTimes: prevRenderTimes } = prev as InternalTableProps<any>;
const { _renderTimes: nextRenderTimes } = next as InternalTableProps<any>;
return prevRenderTimes !== nextRenderTimes;
});