-
-
Notifications
You must be signed in to change notification settings - Fork 4.6k
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
Update: improve report location for space-infix-ops #12324
Conversation
One thing confuses me. In the docs (https://eslint.org/docs/developer-guide/working-with-rules#working-with-rules) the location column is said to be 0-based, but in test cases the location column is 1-based. What's wrong? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks!
I guess one reason context.reports expects 0-based column is that it allows passing a token location with And one reason that problems.column is 1-based is that it is a more human friendly format, for example most editors display 1-based columns. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks!
Two more 👍 to accept this.
Given that we have a champion and three approvals from the team, I'm marking this as accepted. |
What is the purpose of this pull request? (put an "X" next to item)
[x] Changes an existing rule
What changes did you make? (Give an overview)
Make
space-infix-ops
report end location.Is there anything you'd like reviewers to focus on?
No