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

Eslint and Clang format indentation conflicts #745

Closed
alschmiedt opened this issue Jun 1, 2021 · 1 comment
Closed

Eslint and Clang format indentation conflicts #745

alschmiedt opened this issue Jun 1, 2021 · 1 comment
Labels
type: feature request New feature or request
Projects

Comments

@alschmiedt
Copy link
Contributor

Category
Release

Component

Is your feature request related to a problem? Please describe.
Since we have started using Clang format we have started to run into places where eslint and clang rules do not match up.

Describe the solution you'd like
According to this comment it seems like eslint and clang format do not always play nice when it comes to indenting. The best way to deal with this seems to be to turn off eslint indentation rules, and then add some check to make sure that the files are formatted correctly using clang. Something like this github action might come in handy.

Describe alternatives you've considered

  • A developer can run clang format and then eslint --fix. This doesn't work great when a developer is formatting every time they save a file. It also means a developer has to remember to do this every time before they commit.
  • We can try to update eslint indentation rules to match clang as we go. This seems like a lot of work and like it would be difficult to get this a hundred percent correct.

Additional context
Once we come up with a solution we like, we should move it over to core.

@alschmiedt alschmiedt added the type: feature request New feature or request label Jun 1, 2021
@alschmiedt alschmiedt added this to the Release process bash milestone Jun 1, 2021
@alschmiedt alschmiedt added this to To Do P0/P1 in 2021 Q4 via automation Oct 13, 2021
@alschmiedt alschmiedt moved this from To Do P0/P1 to To Do P2 in 2021 Q4 Oct 13, 2021
@alschmiedt
Copy link
Contributor Author

In core we fixed this problem by removing the indentation rules for eslint. I am assuming we are going to do this here as well, so removing this issue in favor of #962.

2021 Q4 automation moved this from To Do P2 to Done Dec 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: feature request New feature or request
Projects
Development

No branches or pull requests

1 participant