Closed oscard0m closed 2 years ago
@yannbf let me know if you need any other detail or you need me to create an example repository to reproduce the error.
What I would like to assure first is if the content of Checkbox.stories.js
and .eslintrc.js
are correct. From there, I can try to debug and get familiar with the code if you want :)
Wow what a detailed explanation @oscard0m thank you so much for that!! I wish everyone was like you when reporting issues! Your files are correct. The error is legit and it's been fixed in #6, you can try again now!
Seems the issue has been solved. Created a new issue with a new error: https://github.com/storybookjs/eslint-plugin-storybook/issues/7
Describe the bug
Tried lint a project I'm working on with
eslint-plugin-storybook
and getting the following error:To Reproduce
Steps to reproduce the behavior:
npm link
)found 0 vulnerabilities
.eslintrc
with Storybook's ESLint pluginnpm run lint
)ESLint: 7.32.0
TypeError: Cannot read property 'properties' of undefined ...
Checkbox.stories.js
Terminal output
Click to expand!
``` npm run lint:js 20:48:42 > cv2profile@0.1.0 lint:js /Users/xxx/dev/zzz > eslint . --ext js --ext jsx --cache Oops! Something went wrong! :( ESLint: 7.32.0 TypeError: Cannot read property 'properties' of undefined Occurred while linting /Users/xxx/dev/zzz/src/stories/Checkbox.stories.js:8 at ExportDefaultDeclaration (/Users/xxx/dev/open_source/storybookjs/eslint-plugin-storybook/lib/rules/hierarchy-separator.js:34:91) at /Users/xxx/dev/zzz/node_modules/eslint/lib/linter/safe-emitter.js:45:58 at Array.forEach (Expected behaviour
Not sure if I'm not writing a correct story but still I assume ESLint should complain but not throw an exception.