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

Investigate if eslint-plugin-editorconfig can be added somehow #194

Open
voxpelli opened this issue Oct 14, 2021 · 2 comments
Open

Investigate if eslint-plugin-editorconfig can be added somehow #194

voxpelli opened this issue Oct 14, 2021 · 2 comments

Comments

@voxpelli
Copy link
Member

voxpelli commented Oct 14, 2021

What version of this package are you using?

16.0.x

What problem do you want to solve?

.editorconfig is a popular cross-editor way of specifying the preferred basic formatting of an editor. It could be nice to support that one if such a one exists in the project, to ensure it doesn't contradict standard and to get some possibly leaner editor support for those basic things.

It would have to fall back to current setup though when no .editorconfig is found.

Idea came from here: standard/standard-engine#270 (comment)

What do you think is the correct solution to this problem?

Looks like https://github.com/phanect/eslint-plugin-editorconfig could possibly do that.

Are you willing to submit a pull request to implement this change?

Yes!


Could help solving eg. #182 as well, if a projects .editorconfig already bans such lines.

@99linesofcode
Copy link

Seems like a no brainer to me but perhaps there are some downstream consequences to consider.

I'd like to see this get added in. Makes a lot of sense to configure ESLint in such a way that it stays out of people's way when combined with tooling like this.

@99linesofcode
Copy link

99linesofcode commented Jul 8, 2022

I've been playing with this for a bit and found that, at least for vscode, editorconfig does not really conflict with eslint or typescript-eslint. I found that omitting any of the rules that might conflict with editorconfig and leaving those to editorconfig itself seems to work just fine.

In fact, in the case of typescript-eslint configuring indent inside your eslint config is problematic due to the way they have implemented the rule. As can be read in this Github issue.

Maybe there isn't really any point to adding this in if editorconfig takes precedence over eslint in other* integrated development environments.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: No status
Development

No branches or pull requests

2 participants