@gitlab/eslint-plugin 12.1.0 → 12.3.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/CHANGELOG.md +22 -0
- package/lib/configs/default.js +11 -1
- package/package.json +4 -4
- package/scripts/integration_test/bootstrap.sh +6 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,25 @@
|
|
|
1
|
+
# [12.3.0](https://gitlab.com/gitlab-org/frontend/eslint-plugin/compare/v12.2.1...v12.3.0) (2022-05-20)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Features
|
|
5
|
+
|
|
6
|
+
* Enable no-dynamic-require rule to prevent import expressions ([c260068](https://gitlab.com/gitlab-org/frontend/eslint-plugin/commit/c260068542710f5a7417603d4ea0eddefdbb88a4))
|
|
7
|
+
|
|
8
|
+
## [12.2.1](https://gitlab.com/gitlab-org/frontend/eslint-plugin/compare/v12.2.0...v12.2.1) (2022-05-20)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Bug Fixes
|
|
12
|
+
|
|
13
|
+
* Loosen new inherited rules ([08cacf8](https://gitlab.com/gitlab-org/frontend/eslint-plugin/commit/08cacf812534b830f9aa90b9f7c6b90ea2698a56)), closes [/github.com/airbnb/javascript/blob/366bfa66380c08304101c6add46355696e90b348/packages/eslint-config-airbnb-base/rules/es6.js#L67-L68](https://gitlab.com//github.com/airbnb/javascript/blob/366bfa66380c08304101c6add46355696e90b348/packages/eslint-config-airbnb-base/rules/es6.js/issues/L67-L68)
|
|
14
|
+
|
|
15
|
+
# [12.2.0](https://gitlab.com/gitlab-org/frontend/eslint-plugin/compare/v12.1.0...v12.2.0) (2022-04-21)
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
### Features
|
|
19
|
+
|
|
20
|
+
* Update eslint-config-airbnb-base to be eslint@8 compatible ([d006b5b](https://gitlab.com/gitlab-org/frontend/eslint-plugin/commit/d006b5b9bdcbb70d6f8ddf0a89c7c37d59dd6507))
|
|
21
|
+
* Update eslint-plugin-import to have eslint@8 support ([c03cffd](https://gitlab.com/gitlab-org/frontend/eslint-plugin/commit/c03cffd795fe516cb8c9d3d4f152b53c2de91d57))
|
|
22
|
+
|
|
1
23
|
# [12.1.0](https://gitlab.com/gitlab-org/frontend/eslint-plugin/compare/v12.0.1...v12.1.0) (2022-04-07)
|
|
2
24
|
|
|
3
25
|
|
package/lib/configs/default.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const [, ...restrictedGlobals] = require('eslint-config-airbnb-base/rules/variables
|
|
1
|
+
const [, ...restrictedGlobals] = require('eslint-config-airbnb-base/rules/variables').rules[
|
|
2
2
|
'no-restricted-globals'
|
|
3
3
|
];
|
|
4
4
|
|
|
@@ -26,10 +26,12 @@ module.exports = {
|
|
|
26
26
|
ignoreDestructuring: true,
|
|
27
27
|
},
|
|
28
28
|
],
|
|
29
|
+
'default-param-last': 'off',
|
|
29
30
|
'unicorn/filename-case': ['error', { case: 'snakeCase' }],
|
|
30
31
|
'import/prefer-default-export': 'off',
|
|
31
32
|
'import/no-default-export': 'error',
|
|
32
33
|
'import/no-deprecated': 'error',
|
|
34
|
+
'import/no-dynamic-require': ['error', { esmodule: true }],
|
|
33
35
|
'no-implicit-coercion': [
|
|
34
36
|
'error',
|
|
35
37
|
{
|
|
@@ -45,6 +47,14 @@ module.exports = {
|
|
|
45
47
|
ignorePropertyModificationsFor: ['acc', 'accumulator', 'el', 'element', 'state'],
|
|
46
48
|
},
|
|
47
49
|
],
|
|
50
|
+
'no-restricted-exports': [
|
|
51
|
+
'error',
|
|
52
|
+
{
|
|
53
|
+
restrictedNamedExports: [
|
|
54
|
+
'then', // avoid confusion when used with dynamic `import()` promise
|
|
55
|
+
],
|
|
56
|
+
},
|
|
57
|
+
],
|
|
48
58
|
'no-sequences': [
|
|
49
59
|
'error',
|
|
50
60
|
{
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gitlab/eslint-plugin",
|
|
3
|
-
"version": "12.
|
|
3
|
+
"version": "12.3.0",
|
|
4
4
|
"description": "GitLab package for our custom eslint rules",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"scripts": {
|
|
@@ -33,10 +33,10 @@
|
|
|
33
33
|
"@babel/core": "^7.17.0",
|
|
34
34
|
"@babel/eslint-parser": "^7.17.0",
|
|
35
35
|
"@babel/eslint-plugin": "^7.17.7",
|
|
36
|
-
"eslint-config-airbnb-base": "^
|
|
36
|
+
"eslint-config-airbnb-base": "^15.0.0",
|
|
37
37
|
"eslint-config-prettier": "^6.10.0",
|
|
38
38
|
"eslint-plugin-babel": "^5.3.0",
|
|
39
|
-
"eslint-plugin-import": "^2.
|
|
39
|
+
"eslint-plugin-import": "^2.26.0",
|
|
40
40
|
"eslint-plugin-jest": "^23.8.2",
|
|
41
41
|
"eslint-plugin-promise": "^4.2.1",
|
|
42
42
|
"eslint-plugin-unicorn": "^40.1.0",
|
|
@@ -44,7 +44,7 @@
|
|
|
44
44
|
"lodash": "^4.17.21"
|
|
45
45
|
},
|
|
46
46
|
"peerDependencies": {
|
|
47
|
-
"eslint": "^7.27.0"
|
|
47
|
+
"eslint": "^7.27.0 || ^8.0.0"
|
|
48
48
|
},
|
|
49
49
|
"devDependencies": {
|
|
50
50
|
"eslint": "^7.27.0",
|
|
@@ -36,3 +36,9 @@ fi
|
|
|
36
36
|
|
|
37
37
|
echo "Installing $CI_REPOSITORY_URL#$SHA"
|
|
38
38
|
yarn add --dev "${CI_REPOSITORY_URL}#${SHA}"
|
|
39
|
+
|
|
40
|
+
echo "Deduplicate dependencies"
|
|
41
|
+
# Yarn doesn't seem to be smart enough when using URL installs and might
|
|
42
|
+
# end up with a weird state, retaining outdated dependencies
|
|
43
|
+
npx yarn-deduplicate --strategy fewer yarn.lock
|
|
44
|
+
yarn install
|