updated and added and formated .editorconfig#34
Conversation
|
Closes #29 |
| end_of_line = lf | ||
| charset = utf-8 | ||
| insert_final_newline = true | ||
| trim_trailing_whitespace = true |
There was a problem hiding this comment.
| trim_trailing_whitespace = true | |
| trim_trailing_whitespace = true | |
| max_line_length = 120 |
It will mirror Prettier's printWidth.
| root = true | ||
|
|
||
| [*] | ||
| indent_style = tab |
There was a problem hiding this comment.
As currently we have YAML format for template issues that would be broken by a tab-indenting editor. It must use spaces, not tabs. The [*] block sets indent_style = tab for every file, but YAML syntax forbids tab indentation. Prettier already emits spaces for YAML regardless of useTabs, so the .editorconfig should mirror that with an override.
You might consider putting it at the end:
# YAML disallows tab indentation; Prettier emits spaces here too
[*.{yml,yaml}]
indent_style = space
indent_size = 2
| trim_trailing_whitespace = true | ||
|
|
||
| [*.md] | ||
| trim_trailing_whitespace = false |
There was a problem hiding this comment.
I also noticed that package-lock.json has been reformatted. It is generated and owned by npm, which always writes it as 2-space JSON, therefore should not be reformatted.
The .editorconfig should match what npm (and .prettierignore) already do. You might want to consider adding something like this:
[package-lock.json]
indent_style = space
indent_size = 2
nora-weisser
left a comment
There was a problem hiding this comment.
Thank you very much for your contribution! I've made a few comments :)
No description provided.