From 5ff00b0c5d30c3106e7f22dc9db6e7a43fc75c78 Mon Sep 17 00:00:00 2001 From: Jacob Richman Date: Tue, 24 Jun 2025 21:38:25 +0000 Subject: [PATCH] Remove uses of the spread operator that appear to have caused a maximum call stack size exceeded error (#1389) --- packages/cli/src/ui/components/shared/MaxSizedBox.tsx | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/packages/cli/src/ui/components/shared/MaxSizedBox.tsx b/packages/cli/src/ui/components/shared/MaxSizedBox.tsx index ced33a37..cd31ff04 100644 --- a/packages/cli/src/ui/components/shared/MaxSizedBox.tsx +++ b/packages/cli/src/ui/components/shared/MaxSizedBox.tsx @@ -408,7 +408,9 @@ function layoutInkElementAsStyledText( ) { lines.push(currentLine); } - output.push(...lines); + for (const line of lines) { + output.push(line); + } return; } @@ -524,5 +526,7 @@ function layoutInkElementAsStyledText( if (wrappingPart.length > 0) { addWrappingPartToLines(); } - output.push(...lines); + for (const line of lines) { + output.push(line); + } }