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 7, 2017
1 parent 1858d5e commit 9884b3a
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/printer.js
Expand Up @@ -3493,6 +3493,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 9884b3a

Please sign in to comment.