diff options
Diffstat (limited to 'tooling/pogen/pogen.ts')
-rw-r--r-- | tooling/pogen/pogen.ts | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tooling/pogen/pogen.ts b/tooling/pogen/pogen.ts index 391843912..98ecdf785 100644 --- a/tooling/pogen/pogen.ts +++ b/tooling/pogen/pogen.ts @@ -213,6 +213,12 @@ export function processFile(sourceFile: ts.SourceFile) { let e = childNode as ts.JsxText; let s = e.getFullText(); let t = s.split("\n").map(trim).join(" "); + if (s[0] === " ") { + t = " " + t; + } + if (s[s.length - 1] === " ") { + t = t + " "; + } fragments.push(t); } case ts.SyntaxKind.JsxOpeningElement: |