better shorthand detection

pull/7738/head
James Birtles 7 years ago
parent 49555b4b63
commit 31250868ae

@ -87,7 +87,7 @@ export default function readContext(parser: Parser) {
end: value.end,
type: 'Property',
kind: 'init',
shorthand: key === value,
shorthand: value.type === 'Identifier' && value.name === name,
key,
value
};

Loading…
Cancel
Save