diff --git a/src/visitors/Tag.js b/src/visitors/Tag.js index 31edbc7..21a5ab6 100644 --- a/src/visitors/Tag.js +++ b/src/visitors/Tag.js @@ -35,6 +35,16 @@ function getAttributes( ): Array { const classes = []; const attrs = node.attrs + .map(node => { + if (node.val === true) { + return { + ...node, + mustEscape: false, + }; + } + + return node; + }) .map(({name, val, mustEscape}) => { if (/\.\.\./.test(name) && val === true) { return t.jSXSpreadAttribute(parseExpression(name.substr(3), context));