We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c734901 commit 0a6cb51Copy full SHA for 0a6cb51
lib/rules/jsx-indent.js
@@ -214,7 +214,7 @@ module.exports = {
214
// Use the parent in a list or an array
215
if (prevToken.type === 'JSXText' || prevToken.type === 'Punctuator' && prevToken.value === ',') {
216
prevToken = sourceCode.getNodeByRangeIndex(prevToken.range[0]);
217
- prevToken = prevToken.type === 'Literal' ? prevToken.parent : prevToken;
+ prevToken = prevToken.type === 'Literal' || prevToken.type === 'JSXText' ? prevToken.parent : prevToken;
218
// Use the first non-punctuator token in a conditional expression
219
} else if (prevToken.type === 'Punctuator' && prevToken.value === ':') {
220
do {
0 commit comments