From 6f5acadffb514e239e9714ce33bd702541ccc1da Mon Sep 17 00:00:00 2001 From: justinpark Date: Wed, 6 Nov 2024 08:53:27 -0800 Subject: [PATCH] react memo to prevent over-rendering --- superset-frontend/src/components/FilterableTable/index.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/superset-frontend/src/components/FilterableTable/index.tsx b/superset-frontend/src/components/FilterableTable/index.tsx index f77f4aede0eb7..53f2c473f0eb8 100644 --- a/superset-frontend/src/components/FilterableTable/index.tsx +++ b/superset-frontend/src/components/FilterableTable/index.tsx @@ -17,7 +17,7 @@ * under the License. */ import _JSONbig from 'json-bigint'; -import { useEffect, useRef, useState, useMemo } from 'react'; +import { useEffect, useRef, useState, useMemo, memo } from 'react'; import { getMultipleTextDimensions, styled } from '@superset-ui/core'; import { useDebounceValue } from 'src/hooks/useDebounceValue'; import { useCellContentParser } from './useCellContentParser'; @@ -272,4 +272,4 @@ const FilterableTable = ({ ); }; -export default FilterableTable; +export default memo(FilterableTable);