Skip to content

Commit

Permalink
Add an explanatory comment
Browse files Browse the repository at this point in the history
  • Loading branch information
karl committed May 6, 2017
1 parent 0691e15 commit cce840c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/printer.js
Expand Up @@ -3464,6 +3464,9 @@ function printJSXChildren(path, options, print, innerJsxWhitespace) {
// eg; one or more spaces separating two elements
for (let i = 0; i < value.length; ++i) {
children.push(innerJsxWhitespace);
// Because fill expects alternating content and whitespace parts
// we need to include an empty content part between each JSX
// whitespace.
if (i + 1 < value.length) {
children.push('');
}
Expand Down

0 comments on commit cce840c

Please sign in to comment.