eslint-plugin-react-native
eslint-plugin-react-native copied to clipboard
TypeError: Cannot read property 'expression' of null when use inline style
using "eslint-plugin-react": "^7.17.0","eslint-plugin-react-native": "^3.8.1" Here's the stack trace:
TypeError: Cannot read property 'expression' of null
at JSXAttribute (/Users/App/node_modules/eslint-plugin-react-native/lib/rules/no-single-element-style-arrays.js:40:24)
at /Users/App/node_modules/eslint/lib/util/safe-emitter.js:47:58
at Array.forEach (<anonymous>)
at Object.emit (/Users/App/node_modules/eslint/lib/util/safe-emitter.js:47:38)
at NodeEventGenerator.applySelector (/Users/App/node_modules/eslint/lib/util/node-event-generator.js:251:26)
at NodeEventGenerator.applySelectors (/Users/App/node_modules/eslint/lib/util/node-event-generator.js:280:22)
at NodeEventGenerator.enterNode (/Users/App/node_modules/eslint/lib/util/node-event-generator.js:294:14)
at CodePathAnalyzer.enterNode (/Users/App/node_modules/eslint/lib/code-path-analysis/code-path-analyzer.js:608:23)
at Traverser.enter [as _enter] (/Users/App/node_modules/eslint/lib/linter.js:865:28)
at Traverser._traverse (/Users/App/node_modules/eslint/lib/util/traverser.js:132:14)
and here is relevant rules:
"react-native/no-unused-styles": 1,
"react-native/split-platform-components": 1,
"react-native/no-inline-styles": 0,
"react-native/no-color-literals": 0,
"react-native/sort-styles":0,
I'm facing the same issue and it looks like an old problem. Anyone aware of that?