Skip to content

Commit adb8bbb

Browse files
committed
Address formatting baseline review feedback.
Reduce editorconfig duplication, add Go/Makefile tab alignment and max line length, and tighten README wording to avoid config drift and clarify .editorconfig recommendation.
1 parent 2fb532e commit adb8bbb

File tree

2 files changed

+7
-26
lines changed

2 files changed

+7
-26
lines changed

.editorconfig

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -5,23 +5,15 @@ charset = utf-8
55
end_of_line = lf
66
insert_final_newline = true
77
trim_trailing_whitespace = true
8-
9-
[*.{js,jsx,ts,tsx}]
108
indent_style = space
119
indent_size = 4
1210

13-
[*.{json}]
14-
indent_style = space
15-
indent_size = 4
11+
[*.{js,jsx,cjs,mjs,ts,tsx}]
12+
max_line_length = 120
1613

1714
[*.{yml,yaml}]
18-
indent_style = space
1915
indent_size = 2
2016

21-
[*.md]
22-
indent_style = space
23-
indent_size = 4
24-
25-
[Makefile]
17+
[{Makefile,*.go,go.*}]
2618
indent_style = tab
2719

README.md

Lines changed: 4 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -46,23 +46,12 @@ To use it in a project:
4646
}
4747
```
4848

49-
Projects are free to override options locally (for example `tabWidth` or
49+
Projects may override options locally (for example `tabWidth` or
5050
`printWidth`) if they have strong legacy constraints, but this configuration
5151
is intended to be the **default Scality baseline** for new or reformatted
52-
Node.js codebases. YAML defaults to 2-space indentation, JSON and Markdown to
53-
4-space indentation, and Markdown prose is left un-reflowed by default
54-
(`proseWrap: 'preserve'`) to avoid noisy diffs in existing documentation.
55-
56-
## Editor configuration
57-
58-
For a consistent editor experience, you can copy or adapt the `.editorconfig`
59-
from this repository. It aligns with the ESLint and Prettier baselines:
60-
61-
- **JS/TS**: spaces with 4-space indentation.
62-
- **JSON/Markdown**: spaces with 4-space indentation.
63-
- **YAML**: spaces with 2-space indentation.
64-
- `end_of_line = lf`, `insert_final_newline = true`,
65-
`trim_trailing_whitespace = true`.
52+
Node.js codebases. YAML/JSON/Markdown files default to a 2-space indentation
53+
and Markdown prose is left un-reflowed by default (`proseWrap: 'preserve'`),
54+
to avoid noisy diffs in existing documentation.
6655

6756
## Contributing
6857

0 commit comments

Comments
 (0)