Skip to content

Commit 836bc7a

Browse files
authored
Only remove blank line ending for web application files (#1334)
1 parent 0a446be commit 836bc7a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/commands/compile.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ async function importFile(
100100
content = file.content.split(/\r?\n/);
101101

102102
// Avoid appending a blank line on every save, which would cause a web app file to grow each time
103-
if (content.length > 1 && content[content.length - 1] === "") {
103+
if (file.name.includes("/") && content.length > 1 && content[content.length - 1] == "") {
104104
content.pop();
105105
}
106106
} else {

0 commit comments

Comments
 (0)