File tree Expand file tree Collapse file tree 2 files changed +16
-6
lines changed
packages/vscode-js-profile-core/src Expand file tree Collapse file tree 2 files changed +16
-6
lines changed Original file line number Diff line number Diff line change @@ -20,9 +20,12 @@ type CpuProfileLayoutComponent<T> = FunctionComponent<{
20
20
/**
21
21
* Base layout component to display CPU-profile related info.
22
22
*/
23
- export const cpuProfileLayoutFactory =
24
- < T extends { } > ( ) : CpuProfileLayoutComponent < T > =>
25
- ( { data, body : RowBody , filterFooter : FilterFooter } ) => {
23
+ export const cpuProfileLayoutFactory = < T extends { } > ( ) : CpuProfileLayoutComponent < T > => {
24
+ const CpuProfileLayout : CpuProfileLayoutComponent < T > = ( {
25
+ data,
26
+ body : RowBody ,
27
+ filterFooter : FilterFooter ,
28
+ } ) => {
26
29
const RichFilter = useMemo < RichFilterComponent < T > > ( richFilter , [ ] ) ;
27
30
const [ filteredData , setFilteredData ] = useState < IQueryResults < T > | undefined > ( undefined ) ;
28
31
const footer = useMemo (
@@ -50,3 +53,5 @@ export const cpuProfileLayoutFactory =
50
53
</ Fragment >
51
54
) ;
52
55
} ;
56
+ return CpuProfileLayout ;
57
+ } ;
Original file line number Diff line number Diff line change @@ -20,9 +20,12 @@ type HeapProfileLayoutComponent<T> = FunctionComponent<{
20
20
/**
21
21
* Base layout component to display CPU-profile related info.
22
22
*/
23
- export const heapProfileLayoutFactory =
24
- < T extends { } > ( ) : HeapProfileLayoutComponent < T > =>
25
- ( { data, body : RowBody , filterFooter : FilterFooter } ) => {
23
+ export const heapProfileLayoutFactory = < T extends { } > ( ) : HeapProfileLayoutComponent < T > => {
24
+ const HeapProfileLayout : HeapProfileLayoutComponent < T > = ( {
25
+ data,
26
+ body : RowBody ,
27
+ filterFooter : FilterFooter ,
28
+ } ) => {
26
29
const RichFilter = useMemo < RichFilterComponent < T > > ( richFilter , [ ] ) ;
27
30
const [ filteredData , setFilteredData ] = useState < IQueryResults < T > | undefined > ( undefined ) ;
28
31
const footer = useMemo (
@@ -50,3 +53,5 @@ export const heapProfileLayoutFactory =
50
53
</ Fragment >
51
54
) ;
52
55
} ;
56
+ return HeapProfileLayout ;
57
+ } ;
You can’t perform that action at this time.
0 commit comments