New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
no-typos rule crashes #1353
Comments
reduced repro-code:
|
The code is failing on this line of code in const comment = sourceCode.getJSDocComment(node); Is it perhaps an
|
I guess it depends if the |
Yeah, this is definitely the right place to start! I'll try to look into this a bit further, hopefully today. I currently don't understand how your code even triggers the rule 😅, as it's only triggered on Edit: The rule triggers from: Then we try to find the MemberExpression: function(node) {
const relatedComponent = utils.getRelatedComponent(node); The related component is the whole function* subscribeBatch({ b }) {
yield a.bind(b);
} This gets passed into the I'll dig into the |
I created an issue on the eslint repo. Let's see if they have anything to say about it, but to me it looks like the proper fix should be inside eslint. |
Fixed in #1372. |
@yannickcr @ljharb I still ran into another crash with the rule. Trying to figure out why/how... What do you think about writing the I honestly don't really understand what it is actually doing here anyway. Why do we need to parse JSDocComments to figure out if anything is a component? isExplicitComponent: function(node) {
let comment;
try {
comment = sourceCode.getJSDocComment(node);
} catch (e) {
comment = null;
} |
If someone is using inheritance (a hugely bad antipattern), like |
I get this exception when enabling the rule
Will try and track down some code that reproduces
The text was updated successfully, but these errors were encountered: