LazyVim icon indicating copy to clipboard operation
LazyVim copied to clipboard

feat(eslint): add option to disable eslint auto format

Open 27medkamal opened this issue 1 year ago • 4 comments

Description

This adds an option to disable eslint's autoformatting. The reasons for not wanting an auto format by eslint are:

  1. It is generally not recommended to use a linter as a formatter as highlighted by https://typescript-eslint.io/users/what-about-formatting/#:~:text=We%20recommend%20against%20using%20ESLint,dprint%2C%20or%20an%20equivalent%20instead
  2. A personal preference not to have a linter change my code which I'm sure other people share.
  3. As highlighted in the link above, eslint auto format can be quite slow.

I would even argue that this should be the default, but I've left it as is in order not to break anyone's config or ruffle anyone's feathers.

Checklist

27medkamal avatar Jul 30 '24 05:07 27medkamal

This PR is stale because it has been open 30 days with no activity.

github-actions[bot] avatar Aug 30 '24 01:08 github-actions[bot]

Please merge this. Eslint formatting causes constant timeouts for me.

adammfrank avatar Sep 20 '24 19:09 adammfrank

Is there a way I can copy this into a local config so I can turn off eslint formatting?

adammfrank avatar Sep 20 '24 20:09 adammfrank

My workaround for now is to not use the extra but rather set it up myself in my own config. Just copy the nvim-lspconfig part to your personal config and you should be good to go

27medkamal avatar Sep 20 '24 21:09 27medkamal

This PR is stale because it has been open 30 days with no activity.

github-actions[bot] avatar Oct 21 '24 02:10 github-actions[bot]