We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
ConsoleLine
1 parent 4f177e6 commit 102a888Copy full SHA for 102a888
src/main/frontend/pipeline-console-view/pipeline-console/main/ConsoleLine.tsx
@@ -1,4 +1,4 @@
1
-import { useEffect, useRef } from "react";
+import { memo, useEffect, useRef } from "react";
2
3
import { makeReactChildren, tokenizeANSIString } from "./Ansi.tsx";
4
@@ -17,7 +17,7 @@ declare global {
17
}
18
19
// Console output line
20
-export const ConsoleLine = (props: ConsoleLineProps) => {
+export const ConsoleLine = memo(function ConsoleLine(props: ConsoleLineProps) {
21
const ref = useRef<HTMLDivElement>(null);
22
useEffect(() => {
23
const height = ref.current ? ref.current.getBoundingClientRect().height : 0;
@@ -66,4 +66,4 @@ export const ConsoleLine = (props: ConsoleLineProps) => {
66
</div>
67
</pre>
68
);
69
-};
+});
0 commit comments