parent
4958225645
commit
ba96b91f40
@ -261,8 +261,8 @@ pp.jsxParseAttributeValue = function() {
|
||||
// at the beginning of the next one (right brace).
|
||||
|
||||
pp.jsxParseEmptyExpression = function() {
|
||||
let node = this.startNodeAt(this.lastTokEnd, this.lastTokEndLoc);
|
||||
return this.finishNodeAt(node, "JSXEmptyExpression", this.start, this.startLoc);
|
||||
let node = this.startNodeAt(this.state.lastTokEnd, this.state.lastTokEndLoc);
|
||||
return this.finishNodeAt(node, "JSXEmptyExpression", this.state.start, this.state.startLoc);
|
||||
};
|
||||
|
||||
// Parse JSX spread child
|
||||
|
||||
39
test/fixtures/jsx/basic/10/expected.json
vendored
39
test/fixtures/jsx/basic/10/expected.json
vendored
@ -137,8 +137,20 @@
|
||||
},
|
||||
"expression": {
|
||||
"type": "JSXEmptyExpression",
|
||||
"loc": {},
|
||||
"leadingComments": [
|
||||
"start": 4,
|
||||
"end": 27,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 1,
|
||||
"column": 4
|
||||
},
|
||||
"end": {
|
||||
"line": 1,
|
||||
"column": 27
|
||||
}
|
||||
},
|
||||
"leadingComments": null,
|
||||
"innerComments": [
|
||||
{
|
||||
"type": "CommentBlock",
|
||||
"value": " this is a comment ",
|
||||
@ -156,26 +168,7 @@
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
"leadingComments": null,
|
||||
"innerComments": [
|
||||
{
|
||||
"type": "CommentBlock",
|
||||
"value": " this is a comment ",
|
||||
"start": 4,
|
||||
"end": 27,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 1,
|
||||
"column": 4
|
||||
},
|
||||
"end": {
|
||||
"line": 1,
|
||||
"column": 27
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
@ -201,4 +194,4 @@
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user