Skip to content

Commit

Permalink
[playground] Bug fix: prevent growing whitespaces in markdown table t…
Browse files Browse the repository at this point in the history
…oggle (#7041)

Co-authored-by: Bob Ippolito <[email protected]>
  • Loading branch information
potatowagon and etrepum authored Jan 21, 2025
1 parent d9f9924 commit 63958a2
Showing 1 changed file with 3 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -173,10 +173,9 @@ export const TABLE: ElementTransformer = {
// It's TableCellNode so it's just to make flow happy
if ($isTableCellNode(cell)) {
rowOutput.push(
$convertToMarkdownString(PLAYGROUND_TRANSFORMERS, cell).replace(
/\n/g,
'\\n',
),
$convertToMarkdownString(PLAYGROUND_TRANSFORMERS, cell)
.replace(/\n/g, '\\n')
.trim(),
);
if (cell.__headerState === TableCellHeaderStates.ROW) {
isHeaderRow = true;
Expand Down

0 comments on commit 63958a2

Please sign in to comment.