@trebired/code-discipline 4.3.1 → 4.3.2
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/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,10 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to `@trebired/code-discipline` will be documented here.
|
|
4
4
|
|
|
5
|
+
## 4.3.2
|
|
6
|
+
|
|
7
|
+
- Changed the default `minDeclarationName.min` from `3` to `2`, allowing two-character declaration names while still reporting one-character names.
|
|
8
|
+
|
|
5
9
|
## 4.3.1
|
|
6
10
|
|
|
7
11
|
- Added `minDeclarationName`, defaulting to `min: 3`, to report too-short JavaScript and TypeScript function declarations and const identifiers.
|
package/README.md
CHANGED
|
@@ -133,7 +133,7 @@ export default defineCodeDisciplineConfig({
|
|
|
133
133
|
],
|
|
134
134
|
},
|
|
135
135
|
minDeclarationName: {
|
|
136
|
-
min:
|
|
136
|
+
min: 2,
|
|
137
137
|
},
|
|
138
138
|
maxFileLines: {
|
|
139
139
|
max: 500,
|
|
@@ -363,7 +363,7 @@ Reports files whose code line count is at or below `min`, defaulting to `1` when
|
|
|
363
363
|
|
|
364
364
|
### `minDeclarationName`
|
|
365
365
|
|
|
366
|
-
Reports JavaScript and TypeScript `function` declarations and simple `const` identifiers whose names are shorter than `min`, defaulting to `
|
|
366
|
+
Reports JavaScript and TypeScript `function` declarations and simple `const` identifiers whose names are shorter than `min`, defaulting to `2` when the rule is configured.
|
|
367
367
|
|
|
368
368
|
### `maxCharactersPerLine`
|
|
369
369
|
|
|
@@ -4,7 +4,7 @@ import { normalizeRelativePath, uniqueStrings } from "../../shared/utils.js";
|
|
|
4
4
|
import { normalizeRuleExclusions } from "./exclusions.js";
|
|
5
5
|
import { normalizeLoggingOptions } from "./logging-options.js";
|
|
6
6
|
const DEFAULT_MIN_FILE_LINES = 1;
|
|
7
|
-
const DEFAULT_MIN_DECLARATION_NAME =
|
|
7
|
+
const DEFAULT_MIN_DECLARATION_NAME = 2;
|
|
8
8
|
const DEFAULT_MAX_CHARACTERS_PER_LINE = 150;
|
|
9
9
|
function assertRemovedKeys(ruleName, source, keys) {
|
|
10
10
|
for (const key of keys) {
|
package/native/darwin-arm64.node
CHANGED
|
Binary file
|
package/native/darwin-x64.node
CHANGED
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/package.json
CHANGED