eslint-plugin-code-style 1.0.37 → 1.0.39

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -186,7 +186,7 @@ rules: {
186
186
  "code-style/curried-arrow-same-line": "error",
187
187
  "code-style/assignment-value-same-line": "error",
188
188
  "code-style/block-statement-newlines": "error",
189
- "code-style/comment-spacing": "error",
189
+ "code-style/comment-format": "error",
190
190
  "code-style/function-call-spacing": "error",
191
191
  "code-style/function-naming-convention": "error",
192
192
  "code-style/function-params-per-line": "error",
@@ -248,7 +248,7 @@ rules: {
248
248
  | `curried-arrow-same-line` | Curried arrow functions start on same line as `=>`, not on new line |
249
249
  | `assignment-value-same-line` | Assignment values start on same line as `=`, not on new line |
250
250
  | `block-statement-newlines` | Newline after `{` and before `}` in if/for/while/function blocks |
251
- | `comment-spacing` | Space after `//`, space inside `/* */`, convert single-line blocks to `//`, no blank lines between file-top comments |
251
+ | `comment-format` | Space after `//`, space inside `/* */`, convert single-line blocks to `//`, no blank lines between file-top comments |
252
252
  | `function-call-spacing` | No space between function name and `(`: `fn()` not `fn ()` |
253
253
  | `function-naming-convention` | Functions use camelCase, start with verb (get/set/handle/is/has), handlers end with Handler |
254
254
  | `function-params-per-line` | When multiline, each param on own line with consistent indentation |
@@ -554,7 +554,7 @@ for (const item of items) { process(item);
554
554
 
555
555
  ---
556
556
 
557
- ### `comment-spacing`
557
+ ### `comment-format`
558
558
 
559
559
  **What it does:** Enforces proper comment formatting:
560
560
  - Space after `//` in line comments
package/index.d.ts CHANGED
@@ -12,7 +12,7 @@ export type RuleNames =
12
12
  | "code-style/arrow-function-simplify"
13
13
  | "code-style/assignment-value-same-line"
14
14
  | "code-style/block-statement-newlines"
15
- | "code-style/comment-spacing"
15
+ | "code-style/comment-format"
16
16
  | "code-style/curried-arrow-same-line"
17
17
  | "code-style/export-format"
18
18
  | "code-style/function-arguments-format"
@@ -81,7 +81,7 @@ interface PluginRules {
81
81
  "arrow-function-simplify": Rule.RuleModule;
82
82
  "assignment-value-same-line": Rule.RuleModule;
83
83
  "block-statement-newlines": Rule.RuleModule;
84
- "comment-spacing": Rule.RuleModule;
84
+ "comment-format": Rule.RuleModule;
85
85
  "curried-arrow-same-line": Rule.RuleModule;
86
86
  "export-format": Rule.RuleModule;
87
87
  "function-arguments-format": Rule.RuleModule;
package/index.js CHANGED
@@ -1138,7 +1138,7 @@ const blockStatementNewlines = {
1138
1138
  * //This is a comment (missing space)
1139
1139
  * [block]No space after opener[/block]
1140
1140
  */
1141
- const commentSpacing = {
1141
+ const commentFormat = {
1142
1142
  create(context) {
1143
1143
  const sourceCode = context.sourceCode || context.getSourceCode();
1144
1144
 
@@ -8410,7 +8410,7 @@ export default {
8410
8410
  "block-statement-newlines": blockStatementNewlines,
8411
8411
 
8412
8412
  // Comment rules
8413
- "comment-spacing": commentSpacing,
8413
+ "comment-format": commentFormat,
8414
8414
 
8415
8415
  // Function rules
8416
8416
  "function-call-spacing": functionCallSpacing,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eslint-plugin-code-style",
3
- "version": "1.0.37",
3
+ "version": "1.0.39",
4
4
  "description": "A custom ESLint plugin for enforcing consistent code formatting and style rules in React/JSX projects",
5
5
  "main": "index.js",
6
6
  "types": "index.d.ts",