Skip to content
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

fix: [dot-notation] explicitly redefine the rule #314

Closed
wants to merge 3 commits into from
Closed

fix: [dot-notation] explicitly redefine the rule #314

wants to merge 3 commits into from

Conversation

andrefilimono
Copy link

What is the purpose of this pull request? (put an "X" next to item)

[ ] Documentation update
[X] Bug fix
[ ] New feature
[ ] Other, please explain:

What changes did you make? (Give an overview)

The rule @typescript-eslint/dot-notation is explicitly defined now.

Which issue (if any) does this pull request address?

#303

Is there anything you'd like reviewers to focus on?

No

@LinusU
Copy link
Contributor

LinusU commented May 20, 2020

Hmmm, I don't see how this will fix the problem, have you verified that it does?

As you can see in src/index.test.ts, the output hasn't really changed, and we were already using @typescript-eslint/dot-notation, and the normal dot-notation was turned off...

@LinusU
Copy link
Contributor

LinusU commented May 20, 2020

I added my comment on what I think the problem is here: typescript-eslint/typescript-eslint#2047 (comment)

@andrefilimono
Copy link
Author

I spent some time to debug the internals of @typescript-eslint, it works as expected and ESLint applies the correct @typescript-eslint/dot-notation rule in runtime.

But when it comes down to the eslint-config-standard-with-typescript I see that ESLint uses the wrong rule dot-notation instead of @typescript-eslint/dot-notation.
But when I apply changes from this PR it starts using the correct one.
Actually I don't know why, but it just works.

@LinusU
Copy link
Contributor

LinusU commented May 20, 2020

Hmmm, this is super weird. If I modify both .eslintrc.json and __tests__/.eslintrc.json to be exactly the same, and then run npm run lint:eslint I get the error. If I then remove __tests__/.eslintrc.json the error goes away 🤔

in this repo https://github.com/BrainJS/brain.js, after updating to latest eslint-config-standard-with-typescript

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants