@touchspot/eslint-config 5.0.8 → 6.0.0
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/chunk-D7D4PA-g.mjs +13 -0
- package/dist/env-P7bBQuYF.mjs +108 -0
- package/dist/env-P7bBQuYF.mjs.map +1 -0
- package/dist/frameworks/next.d.mts +7 -0
- package/dist/frameworks/next.d.mts.map +1 -0
- package/dist/frameworks/next.mjs +17 -0
- package/dist/frameworks/next.mjs.map +1 -0
- package/dist/frameworks/react.d.mts +7 -0
- package/dist/frameworks/react.d.mts.map +1 -0
- package/dist/frameworks/react.mjs +2 -0
- package/dist/frameworks/tailwindcss.d.mts +27 -0
- package/dist/frameworks/tailwindcss.d.mts.map +1 -0
- package/dist/frameworks/tailwindcss.mjs +39 -0
- package/dist/frameworks/tailwindcss.mjs.map +1 -0
- package/dist/functional-D_M95gZL.mjs +48 -0
- package/dist/functional-D_M95gZL.mjs.map +1 -0
- package/dist/index.d.mts +30 -0
- package/dist/index.d.mts.map +1 -0
- package/dist/index.mjs +233 -0
- package/dist/index.mjs.map +1 -0
- package/dist/react-DgMKdgTt.mjs +45 -0
- package/dist/react-DgMKdgTt.mjs.map +1 -0
- package/dist/types-DzD7blyE.d.mts +8 -0
- package/dist/types-DzD7blyE.d.mts.map +1 -0
- package/package.json +26 -22
- package/dist/lib/default.d.ts +0 -4
- package/dist/lib/default.d.ts.map +0 -1
- package/dist/lib/default.js +0 -3
- package/dist/lib/default.js.map +0 -1
- package/dist/lib/frameworks/next.d.ts +0 -2
- package/dist/lib/frameworks/next.d.ts.map +0 -1
- package/dist/lib/frameworks/next.js +0 -2
- package/dist/lib/frameworks/next.js.map +0 -1
- package/dist/lib/frameworks/react.d.ts +0 -2
- package/dist/lib/frameworks/react.d.ts.map +0 -1
- package/dist/lib/frameworks/react.js +0 -2
- package/dist/lib/frameworks/react.js.map +0 -1
- package/dist/lib/frameworks/tailwindcss.d.ts +0 -2
- package/dist/lib/frameworks/tailwindcss.d.ts.map +0 -1
- package/dist/lib/frameworks/tailwindcss.js +0 -2
- package/dist/lib/frameworks/tailwindcss.js.map +0 -1
- package/dist/src/config.d.ts +0 -13
- package/dist/src/config.d.ts.map +0 -1
- package/dist/src/config.js +0 -36
- package/dist/src/config.js.map +0 -1
- package/dist/src/env.d.ts +0 -7
- package/dist/src/env.d.ts.map +0 -1
- package/dist/src/env.js +0 -21
- package/dist/src/env.js.map +0 -1
- package/dist/src/frameworks/next.d.ts +0 -3
- package/dist/src/frameworks/next.d.ts.map +0 -1
- package/dist/src/frameworks/next.js +0 -8
- package/dist/src/frameworks/next.js.map +0 -1
- package/dist/src/frameworks/react.d.ts +0 -3
- package/dist/src/frameworks/react.d.ts.map +0 -1
- package/dist/src/frameworks/react.js +0 -6
- package/dist/src/frameworks/react.js.map +0 -1
- package/dist/src/frameworks/tailwindcss.d.ts +0 -22
- package/dist/src/frameworks/tailwindcss.d.ts.map +0 -1
- package/dist/src/frameworks/tailwindcss.js +0 -4
- package/dist/src/frameworks/tailwindcss.js.map +0 -1
- package/dist/src/rulesets/better-tailwindcss.d.ts +0 -3
- package/dist/src/rulesets/better-tailwindcss.d.ts.map +0 -1
- package/dist/src/rulesets/better-tailwindcss.js +0 -37
- package/dist/src/rulesets/better-tailwindcss.js.map +0 -1
- package/dist/src/rulesets/check-file.d.ts +0 -3
- package/dist/src/rulesets/check-file.d.ts.map +0 -1
- package/dist/src/rulesets/check-file.js +0 -38
- package/dist/src/rulesets/check-file.js.map +0 -1
- package/dist/src/rulesets/eslint.d.ts +0 -2
- package/dist/src/rulesets/eslint.d.ts.map +0 -1
- package/dist/src/rulesets/eslint.js +0 -25
- package/dist/src/rulesets/eslint.js.map +0 -1
- package/dist/src/rulesets/functional.d.ts +0 -5
- package/dist/src/rulesets/functional.d.ts.map +0 -1
- package/dist/src/rulesets/functional.js +0 -54
- package/dist/src/rulesets/functional.js.map +0 -1
- package/dist/src/rulesets/import-x.d.ts +0 -3
- package/dist/src/rulesets/import-x.d.ts.map +0 -1
- package/dist/src/rulesets/import-x.js +0 -52
- package/dist/src/rulesets/import-x.js.map +0 -1
- package/dist/src/rulesets/next.d.ts +0 -2
- package/dist/src/rulesets/next.d.ts.map +0 -1
- package/dist/src/rulesets/next.js +0 -8
- package/dist/src/rulesets/next.js.map +0 -1
- package/dist/src/rulesets/no-relative-import-paths.d.ts +0 -2
- package/dist/src/rulesets/no-relative-import-paths.d.ts.map +0 -1
- package/dist/src/rulesets/no-relative-import-paths.js +0 -14
- package/dist/src/rulesets/no-relative-import-paths.js.map +0 -1
- package/dist/src/rulesets/perfectionist.d.ts +0 -2
- package/dist/src/rulesets/perfectionist.d.ts.map +0 -1
- package/dist/src/rulesets/perfectionist.js +0 -22
- package/dist/src/rulesets/perfectionist.js.map +0 -1
- package/dist/src/rulesets/react-hooks.d.ts +0 -2
- package/dist/src/rulesets/react-hooks.d.ts.map +0 -1
- package/dist/src/rulesets/react-hooks.js +0 -13
- package/dist/src/rulesets/react-hooks.js.map +0 -1
- package/dist/src/rulesets/react.d.ts +0 -2
- package/dist/src/rulesets/react.d.ts.map +0 -1
- package/dist/src/rulesets/react.js +0 -30
- package/dist/src/rulesets/react.js.map +0 -1
- package/dist/src/rulesets/tseslint.d.ts +0 -4
- package/dist/src/rulesets/tseslint.d.ts.map +0 -1
- package/dist/src/rulesets/tseslint.js +0 -99
- package/dist/src/rulesets/tseslint.js.map +0 -1
- package/dist/src/rulesets/unicorn.d.ts +0 -2
- package/dist/src/rulesets/unicorn.d.ts.map +0 -1
- package/dist/src/rulesets/unicorn.js +0 -17
- package/dist/src/rulesets/unicorn.js.map +0 -1
- package/dist/src/rulesets/unused-imports.d.ts +0 -2
- package/dist/src/rulesets/unused-imports.d.ts.map +0 -1
- package/dist/src/rulesets/unused-imports.js +0 -18
- package/dist/src/rulesets/unused-imports.js.map +0 -1
- package/dist/src/types.d.ts +0 -4
- package/dist/src/types.d.ts.map +0 -1
- package/dist/src/types.js +0 -2
- package/dist/src/types.js.map +0 -1
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
import Functional from "eslint-plugin-functional";
|
|
2
|
-
import { defineConfig } from "eslint/config";
|
|
3
|
-
export const functionalRuleset = () => defineConfig({
|
|
4
|
-
name: "@touchspot/eslint-config/rulesets/functional",
|
|
5
|
-
files: ["**/*.{js,jsx,mjs,cjs,ts,tsx,mts,cts}"],
|
|
6
|
-
ignores: ["**/*.d.*"],
|
|
7
|
-
plugins: {
|
|
8
|
-
functional: Functional,
|
|
9
|
-
},
|
|
10
|
-
rules: {
|
|
11
|
-
"functional/immutable-data": [
|
|
12
|
-
"error",
|
|
13
|
-
{
|
|
14
|
-
ignoreImmediateMutation: true,
|
|
15
|
-
ignoreNonConstDeclarations: { treatParametersAsConst: true },
|
|
16
|
-
},
|
|
17
|
-
],
|
|
18
|
-
"functional/prefer-property-signatures": "error",
|
|
19
|
-
"functional/prefer-readonly-type": "error",
|
|
20
|
-
},
|
|
21
|
-
});
|
|
22
|
-
export const functionalRulesetReact = () => defineConfig({
|
|
23
|
-
name: "@touchspot/eslint-config/rulesets/functional/react",
|
|
24
|
-
files: ["**/*.{js,jsx,mjs,cjs,ts,tsx,mts,cts}"],
|
|
25
|
-
ignores: ["**/*.d.*"],
|
|
26
|
-
rules: {
|
|
27
|
-
"functional/immutable-data": [
|
|
28
|
-
"error",
|
|
29
|
-
{
|
|
30
|
-
ignoreImmediateMutation: true,
|
|
31
|
-
ignoreNonConstDeclarations: { treatParametersAsConst: true },
|
|
32
|
-
ignoreAccessorPattern: ["ref.current", "*Ref.current", "*Atom.*"],
|
|
33
|
-
},
|
|
34
|
-
],
|
|
35
|
-
},
|
|
36
|
-
});
|
|
37
|
-
export const autoDisableTypeAwareFunctionalRules = (options) => {
|
|
38
|
-
if (options.enableTypeAwareRules === false) {
|
|
39
|
-
return defineConfig({
|
|
40
|
-
name: "@touchspot/eslint-config/rulesets/functional/disable-type-aware/all",
|
|
41
|
-
files: ["**/*.{js,jsx,mjs,cjs,ts,tsx,mts,cts}"],
|
|
42
|
-
extends: [Functional.configs.disableTypeChecked],
|
|
43
|
-
});
|
|
44
|
-
}
|
|
45
|
-
if (options.enableTypeAwareRules?.js == null) {
|
|
46
|
-
return defineConfig({
|
|
47
|
-
name: "@touchspot/eslint-config/rulesets/functional/disable-type-aware/js",
|
|
48
|
-
files: ["**/*.{js,jsx,mjs,cjs}"],
|
|
49
|
-
extends: [Functional.configs.disableTypeChecked],
|
|
50
|
-
});
|
|
51
|
-
}
|
|
52
|
-
return [];
|
|
53
|
-
};
|
|
54
|
-
//# sourceMappingURL=functional.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"functional.js","sourceRoot":"","sources":["../../../src/rulesets/functional.ts"],"names":[],"mappings":"AAEA,OAAO,UAAU,MAAM,0BAA0B,CAAC;AAClD,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAI7C,MAAM,CAAC,MAAM,iBAAiB,GAAG,GAAG,EAAE,CACrC,YAAY,CAAC;IACZ,IAAI,EAAE,8CAA8C;IACpD,KAAK,EAAE,CAAC,sCAAsC,CAAC;IAC/C,OAAO,EAAE,CAAC,UAAU,CAAC;IACrB,OAAO,EAAE;QACR,UAAU,EAAE,UAAoB;KAChC;IACD,KAAK,EAAE;QACN,2BAA2B,EAAE;YAC5B,OAAO;YACP;gBACC,uBAAuB,EAAE,IAAI;gBAC7B,0BAA0B,EAAE,EAAE,sBAAsB,EAAE,IAAI,EAAE;aAC5D;SACD;QACD,uCAAuC,EAAE,OAAO;QAChD,iCAAiC,EAAE,OAAO;KAC1C;CACD,CAAC,CAAC;AAEJ,MAAM,CAAC,MAAM,sBAAsB,GAAG,GAAG,EAAE,CAC1C,YAAY,CAAC;IACZ,IAAI,EAAE,oDAAoD;IAC1D,KAAK,EAAE,CAAC,sCAAsC,CAAC;IAC/C,OAAO,EAAE,CAAC,UAAU,CAAC;IACrB,KAAK,EAAE;QACN,2BAA2B,EAAE;YAC5B,OAAO;YACP;gBACC,uBAAuB,EAAE,IAAI;gBAC7B,0BAA0B,EAAE,EAAE,sBAAsB,EAAE,IAAI,EAAE;gBAC5D,qBAAqB,EAAE,CAAC,aAAa,EAAE,cAAc,EAAE,SAAS,CAAC;aACjE;SACD;KACD;CACD,CAAC,CAAC;AAEJ,MAAM,CAAC,MAAM,mCAAmC,GAAG,CAAC,OAAuB,EAAE,EAAE;IAC9E,IAAI,OAAO,CAAC,oBAAoB,KAAK,KAAK,EAAE,CAAC;QAC5C,OAAO,YAAY,CAAC;YACnB,IAAI,EAAE,qEAAqE;YAC3E,KAAK,EAAE,CAAC,sCAAsC,CAAC;YAC/C,OAAO,EAAE,CAAC,UAAU,CAAC,OAAO,CAAC,kBAAoC,CAAC;SAClE,CAAC,CAAC;IACJ,CAAC;IACD,IAAI,OAAO,CAAC,oBAAoB,EAAE,EAAE,IAAI,IAAI,EAAE,CAAC;QAC9C,OAAO,YAAY,CAAC;YACnB,IAAI,EAAE,oEAAoE;YAC1E,KAAK,EAAE,CAAC,uBAAuB,CAAC;YAChC,OAAO,EAAE,CAAC,UAAU,CAAC,OAAO,CAAC,kBAAoC,CAAC;SAClE,CAAC,CAAC;IACJ,CAAC;IACD,OAAO,EAAE,CAAC;AACX,CAAC,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"import-x.d.ts","sourceRoot":"","sources":["../../../src/rulesets/import-x.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,cAAc,wCA8CzB,CAAC;AAEH,eAAO,MAAM,kBAAkB,wCAO5B,CAAC"}
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import { createTypeScriptImportResolver } from "eslint-import-resolver-typescript";
|
|
2
|
-
import ImportX from "eslint-plugin-import-x";
|
|
3
|
-
import { defineConfig } from "eslint/config";
|
|
4
|
-
export const importXRuleset = () => defineConfig({
|
|
5
|
-
name: "@touchspot/eslint-config/rulesets/import-x",
|
|
6
|
-
files: ["**/*.{js,jsx,mjs,cjs,ts,tsx,mts,cts}"],
|
|
7
|
-
extends: [ImportX.flatConfigs.recommended],
|
|
8
|
-
settings: {
|
|
9
|
-
"import-x/internal-regex": "^#.+",
|
|
10
|
-
"import-x/resolver-next": [createTypeScriptImportResolver()],
|
|
11
|
-
},
|
|
12
|
-
rules: {
|
|
13
|
-
"import-x/export": "off",
|
|
14
|
-
"import-x/first": "error",
|
|
15
|
-
"import-x/namespace": "off",
|
|
16
|
-
"import-x/newline-after-import": "error",
|
|
17
|
-
"import-x/no-anonymous-default-export": ["error", { allowArray: true, allowObject: true }],
|
|
18
|
-
"import-x/no-duplicates": "error",
|
|
19
|
-
"import-x/no-named-as-default": "off",
|
|
20
|
-
"import-x/no-named-as-default-member": "off",
|
|
21
|
-
"import-x/no-unresolved": "off",
|
|
22
|
-
"import-x/no-useless-path-segments": "error",
|
|
23
|
-
},
|
|
24
|
-
}, {
|
|
25
|
-
name: "@touchspot/eslint-config/rulesets/import-x/typescript",
|
|
26
|
-
files: ["**/*.{ts,tsx,mts,cts}"],
|
|
27
|
-
extends: [ImportX.flatConfigs.typescript],
|
|
28
|
-
rules: {
|
|
29
|
-
"import-x/consistent-type-specifier-style": "error",
|
|
30
|
-
"import-x/no-default-export": "error",
|
|
31
|
-
},
|
|
32
|
-
}, {
|
|
33
|
-
name: "@touchspot/eslint-config/rulesets/import-x/typescript/allow-default-export",
|
|
34
|
-
files: ["*.config.ts", "*.config.*.ts", "**/*.d.*", "**/global-setup.ts"],
|
|
35
|
-
rules: {
|
|
36
|
-
"import-x/no-default-export": "off",
|
|
37
|
-
},
|
|
38
|
-
}, {
|
|
39
|
-
name: "@touchspot/eslint-config/rulesets/import-x/cjs",
|
|
40
|
-
files: ["**/*.{cjs,cts}"],
|
|
41
|
-
rules: {
|
|
42
|
-
"import-x/no-import-module-exports": "error",
|
|
43
|
-
},
|
|
44
|
-
});
|
|
45
|
-
export const importXRulesetNext = () => defineConfig({
|
|
46
|
-
name: "@touchspot/eslint-config/rulesets/import-x/next",
|
|
47
|
-
files: ["{src/,}app/**/*.{ts,tsx}"],
|
|
48
|
-
rules: {
|
|
49
|
-
"import-x/no-default-export": "off",
|
|
50
|
-
},
|
|
51
|
-
});
|
|
52
|
-
//# sourceMappingURL=import-x.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"import-x.js","sourceRoot":"","sources":["../../../src/rulesets/import-x.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,8BAA8B,EAAE,MAAM,mCAAmC,CAAC;AACnF,OAAO,OAAO,MAAM,wBAAwB,CAAC;AAC7C,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAE7C,MAAM,CAAC,MAAM,cAAc,GAAG,GAAG,EAAE,CAClC,YAAY,CACX;IACC,IAAI,EAAE,4CAA4C;IAClD,KAAK,EAAE,CAAC,sCAAsC,CAAC;IAC/C,OAAO,EAAE,CAAC,OAAO,CAAC,WAAW,CAAC,WAA2B,CAAC;IAC1D,QAAQ,EAAE;QACT,yBAAyB,EAAE,MAAM;QACjC,wBAAwB,EAAE,CAAC,8BAA8B,EAAE,CAAC;KAC5D;IACD,KAAK,EAAE;QACN,iBAAiB,EAAE,KAAK;QACxB,gBAAgB,EAAE,OAAO;QACzB,oBAAoB,EAAE,KAAK;QAC3B,+BAA+B,EAAE,OAAO;QACxC,sCAAsC,EAAE,CAAC,OAAO,EAAE,EAAE,UAAU,EAAE,IAAI,EAAE,WAAW,EAAE,IAAI,EAAE,CAAC;QAC1F,wBAAwB,EAAE,OAAO;QACjC,8BAA8B,EAAE,KAAK;QACrC,qCAAqC,EAAE,KAAK;QAC5C,wBAAwB,EAAE,KAAK;QAC/B,mCAAmC,EAAE,OAAO;KAC5C;CACD,EACD;IACC,IAAI,EAAE,uDAAuD;IAC7D,KAAK,EAAE,CAAC,uBAAuB,CAAC;IAChC,OAAO,EAAE,CAAC,OAAO,CAAC,WAAW,CAAC,UAA0B,CAAC;IACzD,KAAK,EAAE;QACN,0CAA0C,EAAE,OAAO;QACnD,4BAA4B,EAAE,OAAO;KACrC;CACD,EACD;IACC,IAAI,EAAE,4EAA4E;IAClF,KAAK,EAAE,CAAC,aAAa,EAAE,eAAe,EAAE,UAAU,EAAE,oBAAoB,CAAC;IACzE,KAAK,EAAE;QACN,4BAA4B,EAAE,KAAK;KACnC;CACD,EACD;IACC,IAAI,EAAE,gDAAgD;IACtD,KAAK,EAAE,CAAC,gBAAgB,CAAC;IACzB,KAAK,EAAE;QACN,mCAAmC,EAAE,OAAO;KAC5C;CACD,CACD,CAAC;AAEH,MAAM,CAAC,MAAM,kBAAkB,GAAG,GAAG,EAAE,CACtC,YAAY,CAAC;IACZ,IAAI,EAAE,iDAAiD;IACvD,KAAK,EAAE,CAAC,0BAA0B,CAAC;IACnC,KAAK,EAAE;QACN,4BAA4B,EAAE,KAAK;KACnC;CACD,CAAC,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"next.d.ts","sourceRoot":"","sources":["../../../src/rulesets/next.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,WAAW,wCAKrB,CAAC"}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import Next from "@next/eslint-plugin-next";
|
|
2
|
-
import { defineConfig, globalIgnores } from "eslint/config";
|
|
3
|
-
export const nextRuleset = () => defineConfig(globalIgnores([".next/", "out/"]), {
|
|
4
|
-
name: "@touchspot/eslint-config/rulesets/next",
|
|
5
|
-
files: ["**/*.{js,jsx,mjs,cjs,ts,tsx,mts,cts}"],
|
|
6
|
-
extends: [Next.configs["core-web-vitals"]],
|
|
7
|
-
});
|
|
8
|
-
//# sourceMappingURL=next.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"next.js","sourceRoot":"","sources":["../../../src/rulesets/next.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,0BAA0B,CAAC;AAC5C,OAAO,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AAE5D,MAAM,CAAC,MAAM,WAAW,GAAG,GAAG,EAAE,CAC/B,YAAY,CAAC,aAAa,CAAC,CAAC,QAAQ,EAAE,MAAM,CAAC,CAAC,EAAE;IAC/C,IAAI,EAAE,wCAAwC;IAC9C,KAAK,EAAE,CAAC,sCAAsC,CAAC;IAC/C,OAAO,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,iBAAiB,CAAC,CAAC;CAC1C,CAAC,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"no-relative-import-paths.d.ts","sourceRoot":"","sources":["../../../src/rulesets/no-relative-import-paths.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,4BAA4B,wCAWtC,CAAC"}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import NoRelativeImportPaths from "eslint-plugin-no-relative-import-paths";
|
|
2
|
-
import { defineConfig } from "eslint/config";
|
|
3
|
-
export const noRelativeImportPathsRuleset = () => defineConfig({
|
|
4
|
-
name: "@touchspot/eslint-config/rulesets/no-relative-import-paths",
|
|
5
|
-
files: ["**/*.{js,jsx,mjs,cjs,ts,tsx,mts,cts}"],
|
|
6
|
-
ignores: ["**/*.d.*"],
|
|
7
|
-
plugins: {
|
|
8
|
-
"no-relative-import-paths": NoRelativeImportPaths,
|
|
9
|
-
},
|
|
10
|
-
rules: {
|
|
11
|
-
"no-relative-import-paths/no-relative-import-paths": ["error", { allowSameFolder: true }],
|
|
12
|
-
},
|
|
13
|
-
});
|
|
14
|
-
//# sourceMappingURL=no-relative-import-paths.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"no-relative-import-paths.js","sourceRoot":"","sources":["../../../src/rulesets/no-relative-import-paths.ts"],"names":[],"mappings":"AAAA,OAAO,qBAAqB,MAAM,wCAAwC,CAAC;AAC3E,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAE7C,MAAM,CAAC,MAAM,4BAA4B,GAAG,GAAG,EAAE,CAChD,YAAY,CAAC;IACZ,IAAI,EAAE,4DAA4D;IAClE,KAAK,EAAE,CAAC,sCAAsC,CAAC;IAC/C,OAAO,EAAE,CAAC,UAAU,CAAC;IACrB,OAAO,EAAE;QACR,0BAA0B,EAAE,qBAAqB;KACjD;IACD,KAAK,EAAE;QACN,mDAAmD,EAAE,CAAC,OAAO,EAAE,EAAE,eAAe,EAAE,IAAI,EAAE,CAAC;KACzF;CACD,CAAC,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"perfectionist.d.ts","sourceRoot":"","sources":["../../../src/rulesets/perfectionist.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,oBAAoB,wCAmB9B,CAAC"}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import Perfectionist from "eslint-plugin-perfectionist";
|
|
2
|
-
import { defineConfig } from "eslint/config";
|
|
3
|
-
export const perfectionistRuleset = () => defineConfig({
|
|
4
|
-
name: "@touchspot/eslint-config/rulesets/perfectionist",
|
|
5
|
-
files: ["**/*.{js,jsx,mjs,cjs,ts,tsx,mts,cts}"],
|
|
6
|
-
plugins: {
|
|
7
|
-
perfectionist: Perfectionist,
|
|
8
|
-
},
|
|
9
|
-
rules: {
|
|
10
|
-
"perfectionist/sort-exports": ["error", { type: "natural" }],
|
|
11
|
-
"perfectionist/sort-imports": [
|
|
12
|
-
"error",
|
|
13
|
-
{
|
|
14
|
-
type: "natural",
|
|
15
|
-
groups: ["side-effect", "builtin", "external", "subpath", ["parent", "sibling", "index"], "unknown"],
|
|
16
|
-
},
|
|
17
|
-
],
|
|
18
|
-
"perfectionist/sort-named-exports": ["error", { type: "natural" }],
|
|
19
|
-
"perfectionist/sort-named-imports": ["error", { type: "natural" }],
|
|
20
|
-
},
|
|
21
|
-
});
|
|
22
|
-
//# sourceMappingURL=perfectionist.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"perfectionist.js","sourceRoot":"","sources":["../../../src/rulesets/perfectionist.ts"],"names":[],"mappings":"AAAA,OAAO,aAAa,MAAM,6BAA6B,CAAC;AACxD,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAE7C,MAAM,CAAC,MAAM,oBAAoB,GAAG,GAAG,EAAE,CACxC,YAAY,CAAC;IACZ,IAAI,EAAE,iDAAiD;IACvD,KAAK,EAAE,CAAC,sCAAsC,CAAC;IAC/C,OAAO,EAAE;QACR,aAAa,EAAE,aAAa;KAC5B;IACD,KAAK,EAAE;QACN,4BAA4B,EAAE,CAAC,OAAO,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE,CAAC;QAC5D,4BAA4B,EAAE;YAC7B,OAAO;YACP;gBACC,IAAI,EAAE,SAAS;gBACf,MAAM,EAAE,CAAC,aAAa,EAAE,SAAS,EAAE,UAAU,EAAE,SAAS,EAAE,CAAC,QAAQ,EAAE,SAAS,EAAE,OAAO,CAAC,EAAE,SAAS,CAAC;aACpG;SACD;QACD,kCAAkC,EAAE,CAAC,OAAO,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE,CAAC;QAClE,kCAAkC,EAAE,CAAC,OAAO,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE,CAAC;KAClE;CACD,CAAC,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"react-hooks.d.ts","sourceRoot":"","sources":["../../../src/rulesets/react-hooks.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,iBAAiB,wCAU3B,CAAC"}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import ReactHooks from "eslint-plugin-react-hooks";
|
|
2
|
-
import { defineConfig } from "eslint/config";
|
|
3
|
-
export const reactHooksRuleset = () => defineConfig({
|
|
4
|
-
name: "@touchspot/eslint-config/rulesets/react-hooks",
|
|
5
|
-
files: ["**/*.{js,jsx,mjs,cjs,ts,tsx,mts,cts}"],
|
|
6
|
-
extends: [ReactHooks.configs.flat["recommended-latest"]],
|
|
7
|
-
rules: {
|
|
8
|
-
"react-hooks/exhaustive-deps": "error",
|
|
9
|
-
"react-hooks/incompatible-library": "error",
|
|
10
|
-
"react-hooks/unsupported-syntax": "error",
|
|
11
|
-
},
|
|
12
|
-
});
|
|
13
|
-
//# sourceMappingURL=react-hooks.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"react-hooks.js","sourceRoot":"","sources":["../../../src/rulesets/react-hooks.ts"],"names":[],"mappings":"AAAA,OAAO,UAAU,MAAM,2BAA2B,CAAC;AACnD,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAE7C,MAAM,CAAC,MAAM,iBAAiB,GAAG,GAAG,EAAE,CACrC,YAAY,CAAC;IACZ,IAAI,EAAE,+CAA+C;IACrD,KAAK,EAAE,CAAC,sCAAsC,CAAC;IAC/C,OAAO,EAAE,CAAC,UAAU,CAAC,OAAO,CAAC,IAAI,CAAC,oBAAoB,CAAC,CAAC;IACxD,KAAK,EAAE;QACN,6BAA6B,EAAE,OAAO;QACtC,kCAAkC,EAAE,OAAO;QAC3C,gCAAgC,EAAE,OAAO;KACzC;CACD,CAAC,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"react.d.ts","sourceRoot":"","sources":["../../../src/rulesets/react.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,YAAY,wCA2BtB,CAAC"}
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import React from "eslint-plugin-react";
|
|
2
|
-
import { defineConfig } from "eslint/config";
|
|
3
|
-
export const reactRuleset = () => defineConfig({
|
|
4
|
-
name: "@touchspot/eslint-config/rulesets/react",
|
|
5
|
-
files: ["**/*.{jsx,tsx}"],
|
|
6
|
-
extends: [React.configs.flat["recommended"] ?? {}, React.configs.flat["jsx-runtime"] ?? {}],
|
|
7
|
-
languageOptions: {
|
|
8
|
-
parserOptions: {
|
|
9
|
-
jsxPragma: null,
|
|
10
|
-
},
|
|
11
|
-
},
|
|
12
|
-
settings: {
|
|
13
|
-
react: {
|
|
14
|
-
version: "detect",
|
|
15
|
-
},
|
|
16
|
-
},
|
|
17
|
-
rules: {
|
|
18
|
-
"react/button-has-type": "error",
|
|
19
|
-
"react/iframe-missing-sandbox": "error",
|
|
20
|
-
"react/jsx-boolean-value": "error",
|
|
21
|
-
"react/jsx-no-useless-fragment": ["error", { allowExpressions: true }],
|
|
22
|
-
"react/jsx-sort-props": [
|
|
23
|
-
"error",
|
|
24
|
-
{ callbacksLast: true, noSortAlphabetically: true, reservedFirst: ["key", "ref"] },
|
|
25
|
-
],
|
|
26
|
-
"react/prop-types": "off",
|
|
27
|
-
"react/self-closing-comp": "error",
|
|
28
|
-
},
|
|
29
|
-
});
|
|
30
|
-
//# sourceMappingURL=react.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"react.js","sourceRoot":"","sources":["../../../src/rulesets/react.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,qBAAqB,CAAC;AACxC,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAE7C,MAAM,CAAC,MAAM,YAAY,GAAG,GAAG,EAAE,CAChC,YAAY,CAAC;IACZ,IAAI,EAAE,yCAAyC;IAC/C,KAAK,EAAE,CAAC,gBAAgB,CAAC;IACzB,OAAO,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC,aAAa,CAAC,IAAI,EAAE,EAAE,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC,aAAa,CAAC,IAAI,EAAE,CAAC;IAC3F,eAAe,EAAE;QAChB,aAAa,EAAE;YACd,SAAS,EAAE,IAAI;SACf;KACD;IACD,QAAQ,EAAE;QACT,KAAK,EAAE;YACN,OAAO,EAAE,QAAQ;SACjB;KACD;IACD,KAAK,EAAE;QACN,uBAAuB,EAAE,OAAO;QAChC,8BAA8B,EAAE,OAAO;QACvC,yBAAyB,EAAE,OAAO;QAClC,+BAA+B,EAAE,CAAC,OAAO,EAAE,EAAE,gBAAgB,EAAE,IAAI,EAAE,CAAC;QACtE,sBAAsB,EAAE;YACvB,OAAO;YACP,EAAE,aAAa,EAAE,IAAI,EAAE,oBAAoB,EAAE,IAAI,EAAE,aAAa,EAAE,CAAC,KAAK,EAAE,KAAK,CAAC,EAAE;SAClF;QACD,kBAAkB,EAAE,KAAK;QACzB,yBAAyB,EAAE,OAAO;KAClC;CACD,CAAC,CAAC"}
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import type { config } from "../config.js";
|
|
2
|
-
export declare const tseslintRuleset: (options: config.Options) => import("eslint/config").Config[];
|
|
3
|
-
export declare const autoDisableTypeAwareTseslintRules: (options: config.Options) => import("eslint/config").Config[];
|
|
4
|
-
//# sourceMappingURL=tseslint.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"tseslint.d.ts","sourceRoot":"","sources":["../../../src/rulesets/tseslint.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,MAAM,EAAE,qBAAuB;AAE7C,eAAO,MAAM,eAAe,GAAI,SAAS,MAAM,CAAC,OAAO,qCAmFrD,CAAC;AAEH,eAAO,MAAM,iCAAiC,GAAI,SAAS,MAAM,CAAC,OAAO,qCAgBxE,CAAC"}
|
|
@@ -1,99 +0,0 @@
|
|
|
1
|
-
import { defineConfig } from "eslint/config";
|
|
2
|
-
import * as TSESLint from "typescript-eslint";
|
|
3
|
-
export const tseslintRuleset = (options) => defineConfig({
|
|
4
|
-
name: "@touchspot/eslint-config/rulesets/tseslint",
|
|
5
|
-
files: ["**/*.{js,jsx,mjs,cjs,ts,tsx,mts,cts}"],
|
|
6
|
-
extends: [TSESLint.configs.base, TSESLint.configs.eslintRecommended],
|
|
7
|
-
languageOptions: {
|
|
8
|
-
parserOptions: {
|
|
9
|
-
tsconfigRootDir: options.rootDir,
|
|
10
|
-
projectService: options.enableTypeAwareRules === false
|
|
11
|
-
? false
|
|
12
|
-
: {
|
|
13
|
-
defaultProject: options.tsconfig ?? "tsconfig.json",
|
|
14
|
-
allowDefaultProject: options.enableTypeAwareRules?.js === "auto" ? ["*.{js,jsx,mjs,cjs}"] : [],
|
|
15
|
-
},
|
|
16
|
-
},
|
|
17
|
-
},
|
|
18
|
-
}, {
|
|
19
|
-
name: "@touchspot/eslint-config/rulesets/tseslint/base",
|
|
20
|
-
files: ["**/*.{js,jsx,mjs,cjs,ts,tsx,mts,cts}"],
|
|
21
|
-
ignores: ["**/*.d.*"],
|
|
22
|
-
extends: [TSESLint.configs.strictTypeChecked, TSESLint.configs.stylisticTypeChecked],
|
|
23
|
-
rules: {
|
|
24
|
-
"@typescript-eslint/consistent-type-definitions": ["error", "type"],
|
|
25
|
-
"@typescript-eslint/consistent-type-exports": "error",
|
|
26
|
-
"@typescript-eslint/consistent-type-imports": "error",
|
|
27
|
-
"@typescript-eslint/explicit-member-accessibility": ["error", { accessibility: "no-public" }],
|
|
28
|
-
"@typescript-eslint/naming-convention": [
|
|
29
|
-
"error",
|
|
30
|
-
{
|
|
31
|
-
selector: "default",
|
|
32
|
-
format: ["camelCase", "PascalCase", "UPPER_CASE"],
|
|
33
|
-
leadingUnderscore: "forbid",
|
|
34
|
-
trailingUnderscore: "forbid",
|
|
35
|
-
},
|
|
36
|
-
{
|
|
37
|
-
selector: ["parameter", "variable"],
|
|
38
|
-
format: ["camelCase", "PascalCase", "UPPER_CASE"],
|
|
39
|
-
leadingUnderscore: "allow",
|
|
40
|
-
trailingUnderscore: "forbid",
|
|
41
|
-
},
|
|
42
|
-
{
|
|
43
|
-
selector: "typeLike",
|
|
44
|
-
format: ["PascalCase", "UPPER_CASE"],
|
|
45
|
-
leadingUnderscore: "forbid",
|
|
46
|
-
trailingUnderscore: "forbid",
|
|
47
|
-
},
|
|
48
|
-
{
|
|
49
|
-
selector: "default",
|
|
50
|
-
modifiers: ["requiresQuotes"],
|
|
51
|
-
format: null,
|
|
52
|
-
},
|
|
53
|
-
{
|
|
54
|
-
selector: "property",
|
|
55
|
-
filter: {
|
|
56
|
-
regex: "^(_tag|__typename)$",
|
|
57
|
-
match: true,
|
|
58
|
-
},
|
|
59
|
-
format: null,
|
|
60
|
-
},
|
|
61
|
-
],
|
|
62
|
-
"@typescript-eslint/no-namespace": ["error", { allowDeclarations: true }],
|
|
63
|
-
"@typescript-eslint/no-import-type-side-effects": "error",
|
|
64
|
-
"no-shadow": "off",
|
|
65
|
-
"@typescript-eslint/no-shadow": ["error", { allow: ["_", "it"] }],
|
|
66
|
-
"@typescript-eslint/no-unnecessary-condition": ["error", { allowConstantLoopConditions: true }],
|
|
67
|
-
"@typescript-eslint/no-unnecessary-qualifier": "error",
|
|
68
|
-
"@typescript-eslint/no-unused-vars": "off",
|
|
69
|
-
"@typescript-eslint/no-useless-empty-export": "error",
|
|
70
|
-
"@typescript-eslint/parameter-properties": "error",
|
|
71
|
-
"@typescript-eslint/prefer-nullish-coalescing": ["error", { ignoreTernaryTests: true }],
|
|
72
|
-
"@typescript-eslint/prefer-readonly": "error",
|
|
73
|
-
"@typescript-eslint/restrict-template-expressions": ["error", { allowNumber: true }],
|
|
74
|
-
"@typescript-eslint/return-await": ["error", "always"],
|
|
75
|
-
"@typescript-eslint/strict-boolean-expressions": [
|
|
76
|
-
"error",
|
|
77
|
-
{ allowString: false, allowNumber: false, allowNullableObject: false },
|
|
78
|
-
],
|
|
79
|
-
"@typescript-eslint/switch-exhaustiveness-check": "error",
|
|
80
|
-
},
|
|
81
|
-
});
|
|
82
|
-
export const autoDisableTypeAwareTseslintRules = (options) => {
|
|
83
|
-
if (options.enableTypeAwareRules === false) {
|
|
84
|
-
return defineConfig({
|
|
85
|
-
name: "@touchspot/eslint-config/rulesets/tseslint/disable-type-aware/all",
|
|
86
|
-
files: ["**/*.{js,jsx,mjs,cjs,ts,tsx,mts,cts}"],
|
|
87
|
-
extends: [TSESLint.configs.disableTypeChecked],
|
|
88
|
-
});
|
|
89
|
-
}
|
|
90
|
-
if (options.enableTypeAwareRules?.js == null) {
|
|
91
|
-
return defineConfig({
|
|
92
|
-
name: "@touchspot/eslint-config/rulesets/tseslint/disable-type-aware/js",
|
|
93
|
-
files: ["**/*.{js,jsx,mjs,cjs}"],
|
|
94
|
-
extends: [TSESLint.configs.disableTypeChecked],
|
|
95
|
-
});
|
|
96
|
-
}
|
|
97
|
-
return [];
|
|
98
|
-
};
|
|
99
|
-
//# sourceMappingURL=tseslint.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"tseslint.js","sourceRoot":"","sources":["../../../src/rulesets/tseslint.ts"],"names":[],"mappings":"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"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"unicorn.d.ts","sourceRoot":"","sources":["../../../src/rulesets/unicorn.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,cAAc,wCAcxB,CAAC"}
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import Unicorn from "eslint-plugin-unicorn";
|
|
2
|
-
import { defineConfig } from "eslint/config";
|
|
3
|
-
export const unicornRuleset = () => defineConfig({
|
|
4
|
-
name: "@touchspot/eslint-config/rulesets/unicorn",
|
|
5
|
-
files: ["**/*.{js,jsx,mjs,cjs,ts,tsx,mts,cts}"],
|
|
6
|
-
extends: [Unicorn.configs.recommended],
|
|
7
|
-
rules: {
|
|
8
|
-
"unicorn/consistent-function-scoping": ["error", { checkArrowFunctions: false }],
|
|
9
|
-
"unicorn/filename-case": "off",
|
|
10
|
-
"unicorn/no-array-callback-reference": "off",
|
|
11
|
-
"unicorn/no-array-reduce": "off",
|
|
12
|
-
"unicorn/no-null": "off",
|
|
13
|
-
"unicorn/prefer-object-from-entries": "off",
|
|
14
|
-
"unicorn/prevent-abbreviations": "off",
|
|
15
|
-
},
|
|
16
|
-
});
|
|
17
|
-
//# sourceMappingURL=unicorn.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"unicorn.js","sourceRoot":"","sources":["../../../src/rulesets/unicorn.ts"],"names":[],"mappings":"AAAA,OAAO,OAAO,MAAM,uBAAuB,CAAC;AAC5C,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAE7C,MAAM,CAAC,MAAM,cAAc,GAAG,GAAG,EAAE,CAClC,YAAY,CAAC;IACZ,IAAI,EAAE,2CAA2C;IACjD,KAAK,EAAE,CAAC,sCAAsC,CAAC;IAC/C,OAAO,EAAE,CAAC,OAAO,CAAC,OAAO,CAAC,WAAW,CAAC;IACtC,KAAK,EAAE;QACN,qCAAqC,EAAE,CAAC,OAAO,EAAE,EAAE,mBAAmB,EAAE,KAAK,EAAE,CAAC;QAChF,uBAAuB,EAAE,KAAK;QAC9B,qCAAqC,EAAE,KAAK;QAC5C,yBAAyB,EAAE,KAAK;QAChC,iBAAiB,EAAE,KAAK;QACxB,oCAAoC,EAAE,KAAK;QAC3C,+BAA+B,EAAE,KAAK;KACtC;CACD,CAAC,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"unused-imports.d.ts","sourceRoot":"","sources":["../../../src/rulesets/unused-imports.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,oBAAoB,wCAe9B,CAAC"}
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import UnusedImports from "eslint-plugin-unused-imports";
|
|
2
|
-
import { defineConfig } from "eslint/config";
|
|
3
|
-
export const unusedImportsRuleset = () => defineConfig({
|
|
4
|
-
name: "@touchspot/eslint-config/rulesets/unused-imports",
|
|
5
|
-
files: ["**/*.{js,jsx,mjs,cjs,ts,tsx,mts,cts}"],
|
|
6
|
-
plugins: {
|
|
7
|
-
"unused-imports": UnusedImports,
|
|
8
|
-
},
|
|
9
|
-
rules: {
|
|
10
|
-
"no-unused-vars": "off",
|
|
11
|
-
"unused-imports/no-unused-imports": "error",
|
|
12
|
-
"unused-imports/no-unused-vars": [
|
|
13
|
-
"error",
|
|
14
|
-
{ args: "after-used", argsIgnorePattern: "^_", vars: "all", varsIgnorePattern: "^_" },
|
|
15
|
-
],
|
|
16
|
-
},
|
|
17
|
-
});
|
|
18
|
-
//# sourceMappingURL=unused-imports.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"unused-imports.js","sourceRoot":"","sources":["../../../src/rulesets/unused-imports.ts"],"names":[],"mappings":"AAAA,OAAO,aAAa,MAAM,8BAA8B,CAAC;AACzD,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAE7C,MAAM,CAAC,MAAM,oBAAoB,GAAG,GAAG,EAAE,CACxC,YAAY,CAAC;IACZ,IAAI,EAAE,kDAAkD;IACxD,KAAK,EAAE,CAAC,sCAAsC,CAAC;IAC/C,OAAO,EAAE;QACR,gBAAgB,EAAE,aAAa;KAC/B;IACD,KAAK,EAAE;QACN,gBAAgB,EAAE,KAAK;QACvB,kCAAkC,EAAE,OAAO;QAC3C,+BAA+B,EAAE;YAChC,OAAO;YACP,EAAE,IAAI,EAAE,YAAY,EAAE,iBAAiB,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,iBAAiB,EAAE,IAAI,EAAE;SACrF;KACD;CACD,CAAC,CAAC"}
|
package/dist/src/types.d.ts
DELETED
package/dist/src/types.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAElD,MAAM,MAAM,WAAW,GAAG,UAAU,CAAC,OAAO,YAAY,CAAC,CAAC;AAC1D,MAAM,MAAM,MAAM,GAAG,WAAW,CAAC,MAAM,CAAC,CAAC"}
|
package/dist/src/types.js
DELETED
package/dist/src/types.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/types.ts"],"names":[],"mappings":""}
|