@cabify/eslint-config 3.0.1-beta-19 → 3.0.1-beta-24
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/eslint-config.cjs +1 -0
- package/dist/eslint-config.js +4 -0
- package/dist/eslint.config-XHzFxT-b.cjs +216 -0
- package/dist/eslint.config-c2LFEVEx.js +81566 -0
- package/dist/ts-B06eACnL.cjs +1 -0
- package/dist/ts-wJBM66KR.js +166 -0
- package/package.json +5 -2
- package/.all-contributorsrc +0 -153
- package/CHANGELOG.md +0 -78
- package/CONTRIBUTION.md +0 -6
- package/configs/base.js +0 -71
- package/configs/best-practices.js +0 -344
- package/configs/errors.js +0 -122
- package/configs/es6.js +0 -180
- package/configs/formats.js +0 -6
- package/configs/imports.js +0 -278
- package/configs/jest.js +0 -9
- package/configs/lodash.js +0 -9
- package/configs/node.js +0 -40
- package/configs/postcss.js +0 -7
- package/configs/promises.js +0 -18
- package/configs/react-a11y.js +0 -230
- package/configs/react.js +0 -432
- package/configs/storybook.js +0 -7
- package/configs/strict.js +0 -7
- package/configs/style.js +0 -319
- package/configs/ts.js +0 -163
- package/configs/utils.js +0 -11
- package/configs/variables.js +0 -53
- package/eslint.config.js +0 -8
- package/recommended.js +0 -6
- package/utils.js +0 -11
- package/vite.config.js +0 -33
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("./eslint.config-XHzFxT-b.cjs"),e=require("typescript-eslint"),o={name:"ts-cabify-eslint-config",files:["**/*.ts","**/*.tsx"],rules:{"@typescript-eslint/restrict-template-expressions":["error",{allowAny:!0}],"@typescript-eslint/array-type":["error",{default:"array"}],"@typescript-eslint/consistent-type-definitions":["error","interface"],"@typescript-eslint/member-ordering":"error","@typescript-eslint/explicit-function-return-type":"off","@typescript-eslint/naming-convention":["error",{selector:"default",format:["camelCase"]},{selector:"import",format:["camelCase","PascalCase","UPPER_CASE"]},{selector:["classProperty","objectLiteralProperty","typeProperty"],format:null},{selector:"variableLike",format:["camelCase","PascalCase"]},{selector:"variable",format:["camelCase","PascalCase","UPPER_CASE"]},{selector:["parameterProperty","method","accessor"],format:["camelCase","PascalCase"],leadingUnderscore:"allow"},{selector:"memberLike",modifiers:["private"],format:["camelCase"],leadingUnderscore:"forbid"},{selector:"typeLike",format:["PascalCase"]},{selector:"parameter",format:["camelCase","PascalCase"],leadingUnderscore:"allow"},{selector:"typeParameter",format:["PascalCase"],custom:{regex:"^[A-Z][a-zA-Z]+$",match:!0}},{selector:"interface",format:["PascalCase"],custom:{regex:"^I[A-Z]",match:!1}},{selector:"class",format:["PascalCase"],leadingUnderscore:"forbid"},{selector:"enumMember",format:["UPPER_CASE","PascalCase"]}],"@typescript-eslint/no-non-null-assertion":"off","@typescript-eslint/no-explicit-any":"error","@typescript-eslint/no-unused-expressions":["error",{allowShortCircuit:!0,allowTernary:!0,allowTaggedTemplates:!1}],"@typescript-eslint/no-unused-vars":["error",{ignoreRestSiblings:!0,argsIgnorePattern:"^_"}],"@typescript-eslint/no-use-before-define":["error",{functions:!0,classes:!0,variables:!0}],"@typescript-eslint/no-redeclare":["error"],"@typescript-eslint/no-shadow":["error"],"@typescript-eslint/explicit-module-boundary-types":"off","@typescript-eslint/no-unsafe-member-access":"off","@typescript-eslint/no-unsafe-assignment":"off","@typescript-eslint/no-unsafe-call":"off","@typescript-eslint/no-unsafe-return":"off",camelcase:"off","import/no-cycle":"off","import/no-default-export":"error","import/named":"off","import/namespace":"off","import/default":"off","import/no-named-as-default-member":"off","react/sort-comp":"off","react/prop-types":"off","react/require-default-props":"off","react/default-props-match-prop-types":"off","no-unused-expressions":"off","no-unused-vars":"off","import/prefer-default-export":"off","no-useless-constructor":"off","@typescript-eslint/no-useless-constructor":"error","no-use-before-define":"off","no-redeclare":"off","no-shadow":"off"},languageOptions:{parserOptions:{projectService:!0,tsconfigRootDir:s.path.resolve(process.cwd())}},ignores:["*.d.ts"]},r=e.config(e.configs.recommended,e.configs.recommendedTypeChecked,o);r.length&&r.forEach(t=>{t.files=["**/*.ts","**/*.tsx"],t.ignores=["**/*.d.ts"]});exports.tsLintConfig=r;
|
|
@@ -0,0 +1,166 @@
|
|
|
1
|
+
import { p as s } from "./eslint.config-c2LFEVEx.js";
|
|
2
|
+
import e from "typescript-eslint";
|
|
3
|
+
const o = {
|
|
4
|
+
name: "ts-cabify-eslint-config",
|
|
5
|
+
files: ["**/*.ts", "**/*.tsx"],
|
|
6
|
+
rules: {
|
|
7
|
+
"@typescript-eslint/restrict-template-expressions": [
|
|
8
|
+
"error",
|
|
9
|
+
{ allowAny: !0 }
|
|
10
|
+
],
|
|
11
|
+
"@typescript-eslint/array-type": ["error", { default: "array" }],
|
|
12
|
+
"@typescript-eslint/consistent-type-definitions": ["error", "interface"],
|
|
13
|
+
"@typescript-eslint/member-ordering": "error",
|
|
14
|
+
"@typescript-eslint/explicit-function-return-type": "off",
|
|
15
|
+
"@typescript-eslint/naming-convention": [
|
|
16
|
+
"error",
|
|
17
|
+
{
|
|
18
|
+
selector: "default",
|
|
19
|
+
format: ["camelCase"]
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
selector: "import",
|
|
23
|
+
format: ["camelCase", "PascalCase", "UPPER_CASE"]
|
|
24
|
+
},
|
|
25
|
+
{
|
|
26
|
+
// This is the 'property' group values. For some reason `property` selector is not recogniced.
|
|
27
|
+
selector: ["classProperty", "objectLiteralProperty", "typeProperty"],
|
|
28
|
+
format: null
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
selector: "variableLike",
|
|
32
|
+
format: ["camelCase", "PascalCase"]
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
selector: "variable",
|
|
36
|
+
format: ["camelCase", "PascalCase", "UPPER_CASE"]
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
// 'memberLike' group selector values without 'property' and 'enumMember'.
|
|
40
|
+
// Don't know why 'memberLike' selector it's not being overriden by 'property' and 'enumMember'
|
|
41
|
+
selector: ["parameterProperty", "method", "accessor"],
|
|
42
|
+
format: ["camelCase", "PascalCase"],
|
|
43
|
+
leadingUnderscore: "allow"
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
selector: "memberLike",
|
|
47
|
+
modifiers: ["private"],
|
|
48
|
+
format: ["camelCase"],
|
|
49
|
+
leadingUnderscore: "forbid"
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
selector: "typeLike",
|
|
53
|
+
format: ["PascalCase"]
|
|
54
|
+
},
|
|
55
|
+
// Allow leading underscore for untyped parameters on Ts
|
|
56
|
+
// Also allow paramters to be PascalCase to receive React.Components as props.
|
|
57
|
+
{
|
|
58
|
+
selector: "parameter",
|
|
59
|
+
format: ["camelCase", "PascalCase"],
|
|
60
|
+
leadingUnderscore: "allow"
|
|
61
|
+
},
|
|
62
|
+
// Enforce the names of generic types are at least 2 characters long
|
|
63
|
+
{
|
|
64
|
+
selector: "typeParameter",
|
|
65
|
+
format: ["PascalCase"],
|
|
66
|
+
custom: {
|
|
67
|
+
regex: "^[A-Z][a-zA-Z]+$",
|
|
68
|
+
match: !0
|
|
69
|
+
}
|
|
70
|
+
},
|
|
71
|
+
// Enforce that interface names do not begin with an I
|
|
72
|
+
{
|
|
73
|
+
selector: "interface",
|
|
74
|
+
format: ["PascalCase"],
|
|
75
|
+
custom: {
|
|
76
|
+
regex: "^I[A-Z]",
|
|
77
|
+
match: !1
|
|
78
|
+
}
|
|
79
|
+
},
|
|
80
|
+
// Emulate the old @typescript-eslint/class-name-casing
|
|
81
|
+
{
|
|
82
|
+
selector: "class",
|
|
83
|
+
format: ["PascalCase"],
|
|
84
|
+
leadingUnderscore: "forbid"
|
|
85
|
+
},
|
|
86
|
+
{
|
|
87
|
+
selector: "enumMember",
|
|
88
|
+
format: ["UPPER_CASE", "PascalCase"]
|
|
89
|
+
}
|
|
90
|
+
],
|
|
91
|
+
"@typescript-eslint/no-non-null-assertion": "off",
|
|
92
|
+
"@typescript-eslint/no-explicit-any": "error",
|
|
93
|
+
"@typescript-eslint/no-unused-expressions": [
|
|
94
|
+
"error",
|
|
95
|
+
{
|
|
96
|
+
allowShortCircuit: !0,
|
|
97
|
+
allowTernary: !0,
|
|
98
|
+
allowTaggedTemplates: !1
|
|
99
|
+
}
|
|
100
|
+
],
|
|
101
|
+
"@typescript-eslint/no-unused-vars": [
|
|
102
|
+
"error",
|
|
103
|
+
{ ignoreRestSiblings: !0, argsIgnorePattern: "^_" }
|
|
104
|
+
],
|
|
105
|
+
"@typescript-eslint/no-use-before-define": [
|
|
106
|
+
"error",
|
|
107
|
+
{ functions: !0, classes: !0, variables: !0 }
|
|
108
|
+
],
|
|
109
|
+
"@typescript-eslint/no-redeclare": ["error"],
|
|
110
|
+
"@typescript-eslint/no-shadow": ["error"],
|
|
111
|
+
"@typescript-eslint/explicit-module-boundary-types": "off",
|
|
112
|
+
// Disabled after upgraded parser
|
|
113
|
+
"@typescript-eslint/no-unsafe-member-access": "off",
|
|
114
|
+
// Disabled after upgraded parser
|
|
115
|
+
"@typescript-eslint/no-unsafe-assignment": "off",
|
|
116
|
+
// Disabled after upgraded parser
|
|
117
|
+
"@typescript-eslint/no-unsafe-call": "off",
|
|
118
|
+
// Disabled after upgraded parser
|
|
119
|
+
"@typescript-eslint/no-unsafe-return": "off",
|
|
120
|
+
// Disabled after upgraded parser
|
|
121
|
+
camelcase: "off",
|
|
122
|
+
// superseeded by @typescript-eslint/naming-conventions
|
|
123
|
+
"import/no-cycle": "off",
|
|
124
|
+
"import/no-default-export": "error",
|
|
125
|
+
// https://github.com/typescript-eslint/typescript-eslint/blob/master/docs/getting-started/linting/FAQ.md#eslint-plugin-import
|
|
126
|
+
"import/named": "off",
|
|
127
|
+
"import/namespace": "off",
|
|
128
|
+
"import/default": "off",
|
|
129
|
+
"import/no-named-as-default-member": "off",
|
|
130
|
+
"react/sort-comp": "off",
|
|
131
|
+
"react/prop-types": "off",
|
|
132
|
+
// guaranteed by TS prop interfaces
|
|
133
|
+
"react/require-default-props": "off",
|
|
134
|
+
"react/default-props-match-prop-types": "off",
|
|
135
|
+
"no-unused-expressions": "off",
|
|
136
|
+
// superseeded by @typescript-eslint/no-unused-expressions
|
|
137
|
+
"no-unused-vars": "off",
|
|
138
|
+
// superseeded by @typescript-eslint/no-unused-vars
|
|
139
|
+
"import/prefer-default-export": "off",
|
|
140
|
+
"no-useless-constructor": "off",
|
|
141
|
+
"@typescript-eslint/no-useless-constructor": "error",
|
|
142
|
+
"no-use-before-define": "off",
|
|
143
|
+
// superseeded by @typescript-eslint/no-use-before-define
|
|
144
|
+
"no-redeclare": "off",
|
|
145
|
+
// superseeded by @typescript-eslint/no-redeclare
|
|
146
|
+
"no-shadow": "off"
|
|
147
|
+
// superseeded by @typescript-eslint/no-shadow
|
|
148
|
+
},
|
|
149
|
+
languageOptions: {
|
|
150
|
+
parserOptions: {
|
|
151
|
+
projectService: !0,
|
|
152
|
+
tsconfigRootDir: s.resolve(process.cwd())
|
|
153
|
+
}
|
|
154
|
+
},
|
|
155
|
+
ignores: ["*.d.ts"]
|
|
156
|
+
}, t = e.config(
|
|
157
|
+
e.configs.recommended,
|
|
158
|
+
e.configs.recommendedTypeChecked,
|
|
159
|
+
o
|
|
160
|
+
);
|
|
161
|
+
t.length && t.forEach((r) => {
|
|
162
|
+
r.files = ["**/*.ts", "**/*.tsx"], r.ignores = ["**/*.d.ts"];
|
|
163
|
+
});
|
|
164
|
+
export {
|
|
165
|
+
t as tsLintConfig
|
|
166
|
+
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cabify/eslint-config",
|
|
3
|
-
"version": "3.0.1-beta-
|
|
3
|
+
"version": "3.0.1-beta-24",
|
|
4
4
|
"description": "ESLint config for Cabify Javascript projects",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"scripts": {
|
|
@@ -69,5 +69,8 @@
|
|
|
69
69
|
"volta": {
|
|
70
70
|
"node": "20.14.0",
|
|
71
71
|
"yarn": "1.22.17"
|
|
72
|
-
}
|
|
72
|
+
},
|
|
73
|
+
"files": [
|
|
74
|
+
"dist"
|
|
75
|
+
]
|
|
73
76
|
}
|
package/.all-contributorsrc
DELETED
|
@@ -1,153 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"projectName": "eslint-config",
|
|
3
|
-
"projectOwner": "cabify",
|
|
4
|
-
"repoType": "github",
|
|
5
|
-
"repoHost": "https://github.com",
|
|
6
|
-
"files": ["README.md"],
|
|
7
|
-
"imageSize": 100,
|
|
8
|
-
"commit": true,
|
|
9
|
-
"commitConvention": "none",
|
|
10
|
-
"contributors": [
|
|
11
|
-
{
|
|
12
|
-
"login": "aarongarciah",
|
|
13
|
-
"name": "Aarón García Hervás",
|
|
14
|
-
"avatar_url": "https://avatars.githubusercontent.com/u/7225802?v=4",
|
|
15
|
-
"profile": "https://aarongarciah.com/",
|
|
16
|
-
"contributions": ["code"]
|
|
17
|
-
},
|
|
18
|
-
{
|
|
19
|
-
"login": "alejandrofdiaz",
|
|
20
|
-
"name": "Alejandro",
|
|
21
|
-
"avatar_url": "https://avatars.githubusercontent.com/u/9197247?v=4",
|
|
22
|
-
"profile": "https://github.com/alejandrofdiaz",
|
|
23
|
-
"contributions": ["code"]
|
|
24
|
-
},
|
|
25
|
-
{
|
|
26
|
-
"login": "alexgallardo",
|
|
27
|
-
"name": "Alejandro Gallardo Escobar",
|
|
28
|
-
"avatar_url": "https://avatars.githubusercontent.com/u/7766614?v=4",
|
|
29
|
-
"profile": "https://github.com/alexgallardo",
|
|
30
|
-
"contributions": ["code"]
|
|
31
|
-
},
|
|
32
|
-
{
|
|
33
|
-
"login": "cicloon",
|
|
34
|
-
"name": "Alejandro León",
|
|
35
|
-
"avatar_url": "https://avatars.githubusercontent.com/u/818328?v=4",
|
|
36
|
-
"profile": "https://github.com/cicloon",
|
|
37
|
-
"contributions": ["code"]
|
|
38
|
-
},
|
|
39
|
-
{
|
|
40
|
-
"login": "AlexTemina",
|
|
41
|
-
"name": "Alex Temina",
|
|
42
|
-
"avatar_url": "https://avatars.githubusercontent.com/u/14157093?v=4",
|
|
43
|
-
"profile": "https://github.com/AlexTemina",
|
|
44
|
-
"contributions": ["code"]
|
|
45
|
-
},
|
|
46
|
-
{
|
|
47
|
-
"login": "ArianZargaran",
|
|
48
|
-
"name": "Arian Zargaran",
|
|
49
|
-
"avatar_url": "https://avatars.githubusercontent.com/u/29388744?v=4",
|
|
50
|
-
"profile": "http://www.ari.soy/",
|
|
51
|
-
"contributions": ["code"]
|
|
52
|
-
},
|
|
53
|
-
{
|
|
54
|
-
"login": "carloscasalar",
|
|
55
|
-
"name": "Carlos Castillo",
|
|
56
|
-
"avatar_url": "https://avatars.githubusercontent.com/u/6154549?v=4",
|
|
57
|
-
"profile": "https://github.com/carloscasalar",
|
|
58
|
-
"contributions": ["code"]
|
|
59
|
-
},
|
|
60
|
-
{
|
|
61
|
-
"login": "christiandebarrio",
|
|
62
|
-
"name": "Christian",
|
|
63
|
-
"avatar_url": "https://avatars.githubusercontent.com/u/13832650?v=4",
|
|
64
|
-
"profile": "https://github.com/christiandebarrio",
|
|
65
|
-
"contributions": ["code"]
|
|
66
|
-
},
|
|
67
|
-
{
|
|
68
|
-
"login": "Crismmgg",
|
|
69
|
-
"name": "Crismmgg",
|
|
70
|
-
"avatar_url": "https://avatars.githubusercontent.com/u/56558107?v=4",
|
|
71
|
-
"profile": "https://github.com/Crismmgg",
|
|
72
|
-
"contributions": ["code"]
|
|
73
|
-
},
|
|
74
|
-
{
|
|
75
|
-
"login": "d-asensio",
|
|
76
|
-
"name": "David Asensio Cañas",
|
|
77
|
-
"avatar_url": "https://avatars.githubusercontent.com/u/13970905?v=4",
|
|
78
|
-
"profile": "https://github.com/d-asensio",
|
|
79
|
-
"contributions": ["code"]
|
|
80
|
-
},
|
|
81
|
-
{
|
|
82
|
-
"login": "inspiratweb",
|
|
83
|
-
"name": "Francisco Sánchez",
|
|
84
|
-
"avatar_url": "https://avatars.githubusercontent.com/u/6814061?v=4",
|
|
85
|
-
"profile": "https://github.com/inspiratweb",
|
|
86
|
-
"contributions": ["code"]
|
|
87
|
-
},
|
|
88
|
-
{
|
|
89
|
-
"login": "jalopez",
|
|
90
|
-
"name": "Javier López",
|
|
91
|
-
"avatar_url": "https://avatars.githubusercontent.com/u/259623?v=4",
|
|
92
|
-
"profile": "https://github.com/jalopez",
|
|
93
|
-
"contributions": ["code"]
|
|
94
|
-
},
|
|
95
|
-
{
|
|
96
|
-
"login": "jmmerino",
|
|
97
|
-
"name": "Jesús Merino Parra",
|
|
98
|
-
"avatar_url": "https://avatars.githubusercontent.com/u/1152640?v=4",
|
|
99
|
-
"profile": "https://github.com/jmmerino",
|
|
100
|
-
"contributions": ["code"]
|
|
101
|
-
},
|
|
102
|
-
{
|
|
103
|
-
"login": "leireriel",
|
|
104
|
-
"name": "Leire Rico",
|
|
105
|
-
"avatar_url": "https://avatars.githubusercontent.com/u/48056077?v=4",
|
|
106
|
-
"profile": "https://leireriel.github.io/leire-rico-portfolio/#/",
|
|
107
|
-
"contributions": ["code"]
|
|
108
|
-
},
|
|
109
|
-
{
|
|
110
|
-
"login": "riboher",
|
|
111
|
-
"name": "Ricardo Boluda",
|
|
112
|
-
"avatar_url": "https://avatars.githubusercontent.com/u/11684090?v=4",
|
|
113
|
-
"profile": "https://github.com/riboher",
|
|
114
|
-
"contributions": ["code"]
|
|
115
|
-
},
|
|
116
|
-
{
|
|
117
|
-
"login": "area73",
|
|
118
|
-
"name": "Rodrigo",
|
|
119
|
-
"avatar_url": "https://avatars.githubusercontent.com/u/2030605?v=4",
|
|
120
|
-
"profile": "http://www.siete3.com/",
|
|
121
|
-
"contributions": ["code"]
|
|
122
|
-
},
|
|
123
|
-
{
|
|
124
|
-
"login": "humanrender",
|
|
125
|
-
"name": "Sergio Ramirez",
|
|
126
|
-
"avatar_url": "https://avatars.githubusercontent.com/u/161557?v=4",
|
|
127
|
-
"profile": "https://github.com/humanrender",
|
|
128
|
-
"contributions": ["code"]
|
|
129
|
-
},
|
|
130
|
-
{
|
|
131
|
-
"login": "valenber",
|
|
132
|
-
"name": "Valentin Berlin",
|
|
133
|
-
"avatar_url": "https://avatars.githubusercontent.com/u/7880641?v=4",
|
|
134
|
-
"profile": "https://valya.codes/",
|
|
135
|
-
"contributions": ["code"]
|
|
136
|
-
},
|
|
137
|
-
{
|
|
138
|
-
"login": "YagoQuinoy",
|
|
139
|
-
"name": "Yago Quiñoy Lobariñas",
|
|
140
|
-
"avatar_url": "https://avatars.githubusercontent.com/u/2685554?v=4",
|
|
141
|
-
"profile": "https://github.com/YagoQuinoy",
|
|
142
|
-
"contributions": ["code"]
|
|
143
|
-
},
|
|
144
|
-
{
|
|
145
|
-
"login": "alejandromolero",
|
|
146
|
-
"name": "alejandromolero",
|
|
147
|
-
"avatar_url": "https://avatars.githubusercontent.com/u/5390467?v=4",
|
|
148
|
-
"profile": "https://github.com/alejandromolero",
|
|
149
|
-
"contributions": ["code"]
|
|
150
|
-
}
|
|
151
|
-
],
|
|
152
|
-
"contributorsPerLine": 7
|
|
153
|
-
}
|
package/CHANGELOG.md
DELETED
|
@@ -1,78 +0,0 @@
|
|
|
1
|
-
# Changelog
|
|
2
|
-
|
|
3
|
-
All notable changes to this project will be documented in this file.
|
|
4
|
-
|
|
5
|
-
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
6
|
-
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
|
-
|
|
8
|
-
## [Unreleased]
|
|
9
|
-
|
|
10
|
-
## [2.1.4] - 2024-09-12
|
|
11
|
-
|
|
12
|
-
- Fixing dependencies not published properly in `v2.1.3`.
|
|
13
|
-
- Revert eslint-plugin-lodash version bump because it requires ESLint v9.
|
|
14
|
-
|
|
15
|
-
## [2.1.3] - 2024-09-12
|
|
16
|
-
|
|
17
|
-
- Updating eslint-plugin dependencies.
|
|
18
|
-
|
|
19
|
-
## [2.1.2] - 2024-09-12
|
|
20
|
-
|
|
21
|
-
- Updating typescript-eslint dependencies.
|
|
22
|
-
|
|
23
|
-
## [2.1.1] - 2024-07-10
|
|
24
|
-
|
|
25
|
-
- Updating naming convention for imports. Added `camelCase`, `PascalCase` and `UPPER_CASE`.
|
|
26
|
-
|
|
27
|
-
## [2.1.0] - 2024-06-20
|
|
28
|
-
|
|
29
|
-
- Updating dependencies before migration to ESlint 9.
|
|
30
|
-
|
|
31
|
-
## [2.0.1] - 2023-07-12
|
|
32
|
-
|
|
33
|
-
- Bumped prettier to v3 and eslint-plugin-prettier to v5 because of [compatibility issues between them](https://github.com/prettier/eslint-plugin-prettier/issues/562).
|
|
34
|
-
|
|
35
|
-
## [2.0.0] - 2023-06-19
|
|
36
|
-
|
|
37
|
-
### Changed
|
|
38
|
-
|
|
39
|
-
- Breaking change in how type imports are sorted [eslint-plugin-simple-import-sort@10.0.0](https://github.com/lydell/eslint-plugin-simple-import-sort/blob/main/CHANGELOG.md#version-1000-2023-01-27).
|
|
40
|
-
- Just run `eslint . --fix`.
|
|
41
|
-
- Bumped dependencies.
|
|
42
|
-
- Bumped `eslint-plugin-import` dependencies [after security alert](https://github.com/cabify/eslint-config/security/dependabot/2).
|
|
43
|
-
|
|
44
|
-
## [1.1.2] - 2022-10-24
|
|
45
|
-
|
|
46
|
-
### Changed
|
|
47
|
-
|
|
48
|
-
- Bump dependencies
|
|
49
|
-
|
|
50
|
-
## [1.0.3] - 2022-07-22
|
|
51
|
-
|
|
52
|
-
### Changed
|
|
53
|
-
|
|
54
|
-
- Bump dependencies
|
|
55
|
-
|
|
56
|
-
## [1.0.2] - 2021-11-25
|
|
57
|
-
|
|
58
|
-
### Changed
|
|
59
|
-
|
|
60
|
-
- Bump dependencies
|
|
61
|
-
|
|
62
|
-
## [1.0.1] - 2021-11-15
|
|
63
|
-
|
|
64
|
-
### Changed
|
|
65
|
-
|
|
66
|
-
- Bump dependencies
|
|
67
|
-
|
|
68
|
-
## [1.0.0] - 2021-10-27
|
|
69
|
-
|
|
70
|
-
### Changed
|
|
71
|
-
|
|
72
|
-
- ESLint v8 is now required as a peer dependency.
|
|
73
|
-
- Node.js 10, 13, and 15 are no longer supported.
|
|
74
|
-
- New rules and changes into some of the old ones.
|
|
75
|
-
|
|
76
|
-
## [0.0.1] - 2021-10-22
|
|
77
|
-
|
|
78
|
-
- Init
|
package/CONTRIBUTION.md
DELETED
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
# Introduction
|
|
2
|
-
|
|
3
|
-
This configuration started as a fork for [airbnb eslint config](https://www.npmjs.com/package/eslint-config-airbnb), most of the rules are similar.
|
|
4
|
-
We have rules divided on files under `configs` folder, in case you need to modify some rule, just think where it belongs and take a look if already exist there.
|
|
5
|
-
|
|
6
|
-
To do updates on this repo just create an MR an a member of this organization will merge it and will publish a version.
|
package/configs/base.js
DELETED
|
@@ -1,71 +0,0 @@
|
|
|
1
|
-
/* eslint-disable import/extensions */
|
|
2
|
-
import globals from 'globals';
|
|
3
|
-
|
|
4
|
-
import bestPractices from './best-practices.js';
|
|
5
|
-
import errors from './errors.js';
|
|
6
|
-
import es6 from './es6.js';
|
|
7
|
-
import formats from './formats.js';
|
|
8
|
-
import imports from './imports.js';
|
|
9
|
-
import jest from './jest.js';
|
|
10
|
-
import lodash from './lodash.js';
|
|
11
|
-
import node from './node.js';
|
|
12
|
-
import postcss from './postcss.js';
|
|
13
|
-
import promises from './promises.js';
|
|
14
|
-
import react from './react.js';
|
|
15
|
-
import reactA11y from './react-a11y.js';
|
|
16
|
-
import storybook from './storybook.js';
|
|
17
|
-
import strict from './strict.js';
|
|
18
|
-
import style from './style.js';
|
|
19
|
-
import { isPackageAvailable } from './utils.js';
|
|
20
|
-
import variables from './variables.js';
|
|
21
|
-
|
|
22
|
-
let isTSAvailable = false;
|
|
23
|
-
let isJestAvailable = false;
|
|
24
|
-
let tsConfigs = [];
|
|
25
|
-
|
|
26
|
-
(async () => {
|
|
27
|
-
isTSAvailable = await isPackageAvailable('typescript');
|
|
28
|
-
isJestAvailable = await isPackageAvailable('jest');
|
|
29
|
-
if (isTSAvailable) {
|
|
30
|
-
const { tsLintConfig } = await import('./ts.js');
|
|
31
|
-
tsConfigs = tsLintConfig;
|
|
32
|
-
}
|
|
33
|
-
})();
|
|
34
|
-
|
|
35
|
-
const configs = [
|
|
36
|
-
bestPractices,
|
|
37
|
-
errors,
|
|
38
|
-
es6,
|
|
39
|
-
...imports,
|
|
40
|
-
node,
|
|
41
|
-
promises,
|
|
42
|
-
strict,
|
|
43
|
-
style,
|
|
44
|
-
variables,
|
|
45
|
-
react,
|
|
46
|
-
lodash,
|
|
47
|
-
reactA11y,
|
|
48
|
-
formats,
|
|
49
|
-
storybook,
|
|
50
|
-
postcss,
|
|
51
|
-
isJestAvailable && jest,
|
|
52
|
-
].filter(Boolean);
|
|
53
|
-
|
|
54
|
-
export default [
|
|
55
|
-
...configs,
|
|
56
|
-
{
|
|
57
|
-
name: 'base-cabify-eslint-config',
|
|
58
|
-
languageOptions: {
|
|
59
|
-
ecmaVersion: 2022,
|
|
60
|
-
sourceType: 'module',
|
|
61
|
-
globals: {
|
|
62
|
-
...globals.browser,
|
|
63
|
-
...globals.node,
|
|
64
|
-
},
|
|
65
|
-
},
|
|
66
|
-
rules: {
|
|
67
|
-
strict: 'error',
|
|
68
|
-
},
|
|
69
|
-
},
|
|
70
|
-
...tsConfigs,
|
|
71
|
-
];
|