Open chandlerprall opened 9 years ago
It appears that prettyPrint
also strips out spaces from JSXElements.
<span>text <a href="#">link</a><span>
becomes
<span>text<a href="#">link</a><span>
where there's no longer a space between text
and the a
tag
I am seeing the same issue
<div>✓</div>
becomes
<div>✓</div>
When pretty printing JSX with HTML entities, the entities are rendered as their display character instead of the source.
print
works as expected -prettyPrint
breaks the output -We are using recast to make AST transforms and convert back to code using prettyPrint. Having
lt;
transformed to<
breaks the subsequent JSX parsing.