Preserve whitespace in JSXExpressionContainer StringLiteral children - fixes T7243
This commit is contained in:
@@ -63,7 +63,7 @@ export default function (opts) {
|
||||
function convertAttribute(node) {
|
||||
let value = convertAttributeValue(node.value || t.booleanLiteral(true));
|
||||
|
||||
if (t.isStringLiteral(value)) {
|
||||
if (t.isStringLiteral(value) && !t.isJSXExpressionContainer(node.value)) {
|
||||
value.value = value.value.replace(/\n\s+/g, " ");
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user