@isentinel/eslint-config 5.0.0-beta.9 → 5.0.1
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/dist/index.d.mts +470 -170
- package/dist/index.mjs +85 -12
- package/package.json +11 -20
package/dist/index.mjs
CHANGED
|
@@ -489,7 +489,8 @@ async function disables(options) {
|
|
|
489
489
|
files: ["**/bin/**/*", `**/bin.${GLOB_SRC_EXT}`],
|
|
490
490
|
rules: {
|
|
491
491
|
"antfu/no-import-dist": "off",
|
|
492
|
-
"antfu/no-import-node-modules-by-path": "off"
|
|
492
|
+
"antfu/no-import-node-modules-by-path": "off",
|
|
493
|
+
"antfu/no-top-level-await": "off"
|
|
493
494
|
}
|
|
494
495
|
},
|
|
495
496
|
{
|
|
@@ -519,6 +520,7 @@ async function disables(options) {
|
|
|
519
520
|
"sonar/no-duplicate-string": "off",
|
|
520
521
|
"ts/explicit-function-return-type": "off",
|
|
521
522
|
"ts/no-empty-function": "off",
|
|
523
|
+
"ts/no-extraneous-class": "off",
|
|
522
524
|
"ts/no-non-null-assertion": "off",
|
|
523
525
|
"ts/unbound-method": "off",
|
|
524
526
|
"unicorn/consistent-function-scoping": "off"
|
|
@@ -1583,14 +1585,65 @@ async function packageJson(options = {}) {
|
|
|
1583
1585
|
"package-json/no-redundant-files": "error",
|
|
1584
1586
|
"package-json/no-redundant-publishConfig": "error",
|
|
1585
1587
|
"package-json/repository-shorthand": "error",
|
|
1588
|
+
"package-json/require-packageManager": "error",
|
|
1586
1589
|
"package-json/require-type": "error",
|
|
1587
1590
|
"package-json/restrict-private-properties": "error",
|
|
1588
|
-
"package-json/
|
|
1589
|
-
|
|
1591
|
+
"package-json/restrict-top-level-properties": ["error", { ban: [
|
|
1592
|
+
{
|
|
1593
|
+
message: "Configure pnpm options in pnpm-workspace.yaml.",
|
|
1594
|
+
property: "pnpm"
|
|
1595
|
+
},
|
|
1596
|
+
{
|
|
1597
|
+
message: "Configure prettier options in eslint config",
|
|
1598
|
+
property: "prettier"
|
|
1599
|
+
},
|
|
1600
|
+
{
|
|
1601
|
+
message: "Configure commitlint in a dedicated config file.",
|
|
1602
|
+
property: "commitlint"
|
|
1603
|
+
},
|
|
1604
|
+
{
|
|
1605
|
+
message: "Configure ESLint in a dedicated config file.",
|
|
1606
|
+
property: "eslintConfig"
|
|
1607
|
+
},
|
|
1608
|
+
{
|
|
1609
|
+
message: "Configure Jest in a dedicated config file.",
|
|
1610
|
+
property: "jest"
|
|
1611
|
+
},
|
|
1612
|
+
{
|
|
1613
|
+
message: "Configure lint-staged in a dedicated config file.",
|
|
1614
|
+
property: "lint-staged"
|
|
1615
|
+
},
|
|
1616
|
+
{
|
|
1617
|
+
message: "Configure Renovate in a renovate config file.",
|
|
1618
|
+
property: "renovate"
|
|
1619
|
+
},
|
|
1620
|
+
{
|
|
1621
|
+
message: "Configure nx in the nx.json file.",
|
|
1622
|
+
property: "nx"
|
|
1623
|
+
},
|
|
1624
|
+
{
|
|
1625
|
+
message: "Configure simple-git-hooks in simple-git-hooks config file.",
|
|
1626
|
+
property: "simple-git-hooks"
|
|
1627
|
+
},
|
|
1628
|
+
{
|
|
1629
|
+
message: "Configure release-it in a dedicated config file.",
|
|
1630
|
+
property: "release-it"
|
|
1631
|
+
},
|
|
1632
|
+
{
|
|
1633
|
+
message: "Configure Stylelint in a dedicated config file.",
|
|
1634
|
+
property: "stylelint"
|
|
1635
|
+
},
|
|
1636
|
+
{
|
|
1637
|
+
message: "Configure TypeDoc in a dedicated config file.",
|
|
1638
|
+
property: "typedoc"
|
|
1639
|
+
}
|
|
1640
|
+
] }],
|
|
1590
1641
|
"package-json/specify-peers-locally": "error",
|
|
1591
1642
|
"package-json/unique-dependencies": "error",
|
|
1592
1643
|
"package-json/valid-author": "off",
|
|
1593
1644
|
"package-json/valid-bin": "error",
|
|
1645
|
+
"package-json/valid-browser": "error",
|
|
1646
|
+
"package-json/valid-bugs": "error",
|
|
1594
1647
|
"package-json/valid-bundleDependencies": "error",
|
|
1595
1648
|
"package-json/valid-config": "error",
|
|
1596
1649
|
"package-json/valid-contributors": "error",
|
|
@@ -1598,12 +1651,16 @@ async function packageJson(options = {}) {
|
|
|
1598
1651
|
"package-json/valid-dependencies": "error",
|
|
1599
1652
|
"package-json/valid-description": "error",
|
|
1600
1653
|
"package-json/valid-devDependencies": "error",
|
|
1654
|
+
"package-json/valid-devEngines": "error",
|
|
1601
1655
|
"package-json/valid-directories": "error",
|
|
1602
1656
|
"package-json/valid-engines": "error",
|
|
1603
1657
|
"package-json/valid-exports": "error",
|
|
1604
1658
|
"package-json/valid-files": "error",
|
|
1659
|
+
"package-json/valid-funding": "error",
|
|
1660
|
+
"package-json/valid-gypfile": "error",
|
|
1605
1661
|
"package-json/valid-homepage": "error",
|
|
1606
1662
|
"package-json/valid-keywords": "error",
|
|
1663
|
+
"package-json/valid-libc": "error",
|
|
1607
1664
|
"package-json/valid-license": "error",
|
|
1608
1665
|
"package-json/valid-main": "error",
|
|
1609
1666
|
"package-json/valid-man": "error",
|
|
@@ -1611,7 +1668,10 @@ async function packageJson(options = {}) {
|
|
|
1611
1668
|
"package-json/valid-name": "error",
|
|
1612
1669
|
"package-json/valid-optionalDependencies": "error",
|
|
1613
1670
|
"package-json/valid-os": "error",
|
|
1671
|
+
"package-json/valid-packageManager": "error",
|
|
1614
1672
|
"package-json/valid-peerDependencies": "error",
|
|
1673
|
+
"package-json/valid-peerDependenciesMeta": "error",
|
|
1674
|
+
"package-json/valid-peerDependenciesMeta-relationship": "error",
|
|
1615
1675
|
"package-json/valid-private": "error",
|
|
1616
1676
|
"package-json/valid-publishConfig": "error",
|
|
1617
1677
|
"package-json/valid-repository": "error",
|
|
@@ -1624,7 +1684,9 @@ async function packageJson(options = {}) {
|
|
|
1624
1684
|
...stylistic !== false ? {
|
|
1625
1685
|
"package-json/bin-name-casing": "error",
|
|
1626
1686
|
"package-json/exports-subpaths-style": ["error", { prefer: "explicit" }],
|
|
1627
|
-
"package-json/order-properties": "error"
|
|
1687
|
+
"package-json/order-properties": "error",
|
|
1688
|
+
"package-json/scripts-name-casing": "error",
|
|
1689
|
+
"package-json/sort-collections": "error"
|
|
1628
1690
|
} : {},
|
|
1629
1691
|
...type === "package" ? {
|
|
1630
1692
|
"package-json/require-attribution": ["error", { ignorePrivate: true }],
|
|
@@ -1633,7 +1695,7 @@ async function packageJson(options = {}) {
|
|
|
1633
1695
|
"package-json/require-exports": ["error", { ignorePrivate: true }],
|
|
1634
1696
|
"package-json/require-files": ["error", { ignorePrivate: true }],
|
|
1635
1697
|
"package-json/require-homepage": ["error", { ignorePrivate: true }],
|
|
1636
|
-
"package-json/require-keywords": "error",
|
|
1698
|
+
"package-json/require-keywords": ["error", { ignorePrivate: true }],
|
|
1637
1699
|
"package-json/require-license": ["error", { ignorePrivate: true }],
|
|
1638
1700
|
"package-json/require-name": "error",
|
|
1639
1701
|
"package-json/require-repository": ["error", { ignorePrivate: true }],
|
|
@@ -1641,7 +1703,9 @@ async function packageJson(options = {}) {
|
|
|
1641
1703
|
"package-json/require-version": "error"
|
|
1642
1704
|
} : {},
|
|
1643
1705
|
...type === "package" && !roblox ? {
|
|
1706
|
+
"package-json/require-bin": ["error", { ignorePrivate: true }],
|
|
1644
1707
|
"package-json/require-engines": "error",
|
|
1708
|
+
"package-json/require-module": "error",
|
|
1645
1709
|
"package-json/require-sideEffects": ["error", { ignorePrivate: true }]
|
|
1646
1710
|
} : {}
|
|
1647
1711
|
}
|
|
@@ -2013,7 +2077,8 @@ async function oxfmt(options) {
|
|
|
2013
2077
|
rules: { "oxfmt/oxfmt": ["error", {
|
|
2014
2078
|
...oxfmtOptions,
|
|
2015
2079
|
printWidth: Number(prettierOptions["jsdocPrintWidth"]) || 80,
|
|
2016
|
-
proseWrap: "always"
|
|
2080
|
+
proseWrap: "always",
|
|
2081
|
+
tabWidth: 2
|
|
2017
2082
|
}] }
|
|
2018
2083
|
});
|
|
2019
2084
|
if (formattingOptions.graphql) configs.push({
|
|
@@ -3366,7 +3431,8 @@ async function test(options = {}) {
|
|
|
3366
3431
|
}
|
|
3367
3432
|
}, {
|
|
3368
3433
|
name: "isentinel/test/jest/rules",
|
|
3369
|
-
files,
|
|
3434
|
+
files: jestOptions.files ?? files,
|
|
3435
|
+
...jestOptions.ignores ? { ignores: jestOptions.ignores } : {},
|
|
3370
3436
|
rules: {
|
|
3371
3437
|
"test/consistent-test-it": "error",
|
|
3372
3438
|
"test/expect-expect": "warn",
|
|
@@ -3428,7 +3494,8 @@ async function test(options = {}) {
|
|
|
3428
3494
|
"jest-extended/prefer-to-have-been-called-once": "error"
|
|
3429
3495
|
} : {},
|
|
3430
3496
|
...stylistic !== false ? { "test/padding-around-all": "warn" } : {},
|
|
3431
|
-
...overrides
|
|
3497
|
+
...overrides,
|
|
3498
|
+
...jestOptions.overrides
|
|
3432
3499
|
},
|
|
3433
3500
|
settings: { jest: {
|
|
3434
3501
|
globalPackage: "@rbxts/jest-globals",
|
|
@@ -3439,7 +3506,7 @@ async function test(options = {}) {
|
|
|
3439
3506
|
if (enableVitest) {
|
|
3440
3507
|
await ensurePackages(["@vitest/eslint-plugin"]);
|
|
3441
3508
|
const vitestPlugin = await interopDefault(import("@vitest/eslint-plugin"));
|
|
3442
|
-
const useJestExtended =
|
|
3509
|
+
const useJestExtended = vitestOptions.extended === true;
|
|
3443
3510
|
const jestExtendedPlugin = await (async () => {
|
|
3444
3511
|
if (!useJestExtended) return;
|
|
3445
3512
|
await ensurePackages(["eslint-plugin-jest-extended"]);
|
|
@@ -3455,7 +3522,8 @@ async function test(options = {}) {
|
|
|
3455
3522
|
}
|
|
3456
3523
|
}, {
|
|
3457
3524
|
name: "isentinel/test/vitest/rules",
|
|
3458
|
-
files,
|
|
3525
|
+
files: vitestOptions.files ?? files,
|
|
3526
|
+
...vitestOptions.ignores ? { ignores: vitestOptions.ignores } : {},
|
|
3459
3527
|
rules: {
|
|
3460
3528
|
"vitest/consistent-each-for": ["error", {
|
|
3461
3529
|
describe: "for",
|
|
@@ -3539,9 +3607,13 @@ async function test(options = {}) {
|
|
|
3539
3607
|
"jest-extended/prefer-to-have-been-called-once": "error"
|
|
3540
3608
|
} : {},
|
|
3541
3609
|
...stylistic !== false ? { "vitest/padding-around-all": "warn" } : {},
|
|
3542
|
-
...overrides
|
|
3610
|
+
...overrides,
|
|
3611
|
+
...vitestOptions.overrides
|
|
3543
3612
|
},
|
|
3544
|
-
settings: {
|
|
3613
|
+
settings: {
|
|
3614
|
+
...useJestExtended ? { jest: { globalPackage: "vitest" } } : {},
|
|
3615
|
+
vitest: { typecheck: vitestOptions.typecheck ?? false }
|
|
3616
|
+
}
|
|
3545
3617
|
});
|
|
3546
3618
|
}
|
|
3547
3619
|
return configs;
|
|
@@ -3614,6 +3686,7 @@ async function typescript(options = {}) {
|
|
|
3614
3686
|
}],
|
|
3615
3687
|
"ts/dot-notation": ["error", { allowKeywords: true }],
|
|
3616
3688
|
"ts/no-confusing-void-expression": "error",
|
|
3689
|
+
"ts/no-deprecated": "error",
|
|
3617
3690
|
"ts/no-duplicate-type-constituents": "error",
|
|
3618
3691
|
"ts/no-empty-object-type": "error",
|
|
3619
3692
|
"ts/no-floating-promises": ["error", { ignoreVoid: true }],
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@isentinel/eslint-config",
|
|
3
|
-
"version": "5.0.
|
|
3
|
+
"version": "5.0.1",
|
|
4
4
|
"description": "iSentinel's ESLint config",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"eslint-config",
|
|
@@ -40,15 +40,6 @@
|
|
|
40
40
|
"bin",
|
|
41
41
|
"dist"
|
|
42
42
|
],
|
|
43
|
-
"simple-git-hooks": {
|
|
44
|
-
"pre-commit": "pnpm install --frozen-lockfile && pnpm lint-staged"
|
|
45
|
-
},
|
|
46
|
-
"lint-staged": {
|
|
47
|
-
"*": "pnpm exec eslint --fix --cache --no-warn-ignored",
|
|
48
|
-
"*.ts": [
|
|
49
|
-
"sh -c 'tsc --noEmit'"
|
|
50
|
-
]
|
|
51
|
-
},
|
|
52
43
|
"dependencies": {
|
|
53
44
|
"@antfu/install-pkg": "1.1.0",
|
|
54
45
|
"@clack/prompts": "1.0.1",
|
|
@@ -56,13 +47,13 @@
|
|
|
56
47
|
"@eslint-community/eslint-plugin-eslint-comments": "4.6.0",
|
|
57
48
|
"@eslint/compat": "2.0.2",
|
|
58
49
|
"@eslint/markdown": "7.5.1",
|
|
59
|
-
"@isentinel/dict-rbxts": "1.0.
|
|
60
|
-
"@isentinel/dict-roblox": "1.0.
|
|
50
|
+
"@isentinel/dict-rbxts": "1.0.10",
|
|
51
|
+
"@isentinel/dict-roblox": "1.0.4",
|
|
61
52
|
"@isentinel/eslint-plugin-comment-length": "2.2.0",
|
|
62
53
|
"@pobammer-ts/eslint-cease-nonsense-rules": "1.30.0",
|
|
63
54
|
"@stylistic/eslint-plugin": "5.9.0",
|
|
64
|
-
"@typescript-eslint/eslint-plugin": "8.
|
|
65
|
-
"@typescript-eslint/parser": "8.
|
|
55
|
+
"@typescript-eslint/eslint-plugin": "8.59.4",
|
|
56
|
+
"@typescript-eslint/parser": "8.59.4",
|
|
66
57
|
"ansis": "4.2.0",
|
|
67
58
|
"eslint-config-flat-gitignore": "2.2.1",
|
|
68
59
|
"eslint-config-prettier": "10.1.8",
|
|
@@ -77,8 +68,8 @@
|
|
|
77
68
|
"eslint-plugin-import-lite": "0.5.2",
|
|
78
69
|
"eslint-plugin-jsdoc": "62.7.1",
|
|
79
70
|
"eslint-plugin-jsonc": "3.0.0",
|
|
80
|
-
"eslint-plugin-oxfmt": "0.
|
|
81
|
-
"eslint-plugin-package-json": "
|
|
71
|
+
"eslint-plugin-oxfmt": "0.8.0",
|
|
72
|
+
"eslint-plugin-package-json": "1.1.0",
|
|
82
73
|
"eslint-plugin-perfectionist": "5.6.0",
|
|
83
74
|
"eslint-plugin-pnpm": "1.5.0",
|
|
84
75
|
"eslint-plugin-promise": "7.2.1",
|
|
@@ -93,7 +84,7 @@
|
|
|
93
84
|
"globals": "17.3.0",
|
|
94
85
|
"jsonc-eslint-parser": "3.1.0",
|
|
95
86
|
"local-pkg": "1.1.2",
|
|
96
|
-
"oxfmt": "0.
|
|
87
|
+
"oxfmt": "0.51.0",
|
|
97
88
|
"prettier": "3.8.1",
|
|
98
89
|
"toml-eslint-parser": "1.0.3",
|
|
99
90
|
"yaml-eslint-parser": "2.0.0",
|
|
@@ -107,12 +98,12 @@
|
|
|
107
98
|
"@stylistic/eslint-plugin-migrate": "4.4.1",
|
|
108
99
|
"@types/node": "22.16.0",
|
|
109
100
|
"@types/yargs": "17.0.35",
|
|
110
|
-
"@vitest/eslint-plugin": "1.6.
|
|
101
|
+
"@vitest/eslint-plugin": "1.6.18",
|
|
111
102
|
"bumpp": "10.4.1",
|
|
112
103
|
"eslint": "9.39.2",
|
|
113
104
|
"eslint-plugin-erasable-syntax-only": "0.4.0",
|
|
114
105
|
"eslint-plugin-eslint-plugin": "7.3.1",
|
|
115
|
-
"eslint-plugin-jest": "29.15.
|
|
106
|
+
"eslint-plugin-jest": "29.15.2",
|
|
116
107
|
"eslint-plugin-jest-extended": "3.0.1",
|
|
117
108
|
"eslint-plugin-n": "17.24.0",
|
|
118
109
|
"eslint-plugin-react-hooks": "7.0.1",
|
|
@@ -131,7 +122,7 @@
|
|
|
131
122
|
"type-fest": "5.4.4",
|
|
132
123
|
"typescript": "5.9.3",
|
|
133
124
|
"unplugin-unused": "0.5.7",
|
|
134
|
-
"@isentinel/eslint-config": "5.0.
|
|
125
|
+
"@isentinel/eslint-config": "5.0.1"
|
|
135
126
|
},
|
|
136
127
|
"peerDependencies": {
|
|
137
128
|
"@vitest/eslint-plugin": "^1.6.4",
|