eslint crashes on .jsx files if react storybook is installed #12457
Labels
archived due to age
This issue has been archived; please open a new issue for any further discussion
bug
ESLint is working incorrectly
evaluating
The team will evaluate this issue to decide whether it meets the criteria for inclusion
With latest eslint and latest react storybook installed, eslint crases in countTrailingLinebreaks while calling
match
on undefined.I've run this through a debugger and undefined there is from an end jsx tag token's
.value
.If I remove react storybook from package.json, wipe node modules and npm install again, then it works. If I then install react storybook afterwords it also works. If I install via
npm i --legacy-bundle
it also works. Which makes me think it is something to do with npm's deduping.What's weird is that we have other repos that also use the same version of eslint, same eslintrc, same plugins and same react storybook and there we don't get any crashes. So it seems to be even more subtle than that.
Tell us about your environment
What parser (default, Babel-ESLint, etc.) are you using?
I'm not sure. Default eslint?
Please show your full configuration:
package.json:
.eslintrc:
What did you do?
This is the source code I'm trying to lint:
test.jsx:
(I get the same with
npm run lint
from package.json above and also$ npx eslint test.jsx
)What did you expect to happen?
I expect it to not crash.
What actually happened?
Are you willing to submit a pull request to fix this bug?
I'd love to, but for now I'm out of ideas. Any pointers for how to continue to debug this further would be greatly appreciated.
The text was updated successfully, but these errors were encountered: