We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c4f13d5 commit 084f090Copy full SHA for 084f090
src/components/utils.ts
@@ -36,6 +36,6 @@ export function parseCodeIntoLines(
36
37
return code
38
.split(/\r?\n/)
39
- .map((line) => line.trimEnd())
40
- .filter((l) => l.length > 0);
+ .map((line) => line.replace(/\s+$/, ''))
+ .filter((line) => line.length > 0 || line === '');
41
}
0 commit comments