@commencis/eslint-config 2.0.0 → 2.1.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 +6 -0
- package/dist/configs/base.js +1 -1
- package/dist/configs/next.js +8 -2
- package/dist/configs/react-native.js +8 -2
- package/dist/configs/react.js +8 -2
- package/dist/configs/typescript.js +8 -2
- package/dist/configs/vue.js +8 -2
- package/dist/index.js +8 -2
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
package/dist/configs/base.js
CHANGED
|
@@ -57,7 +57,7 @@ var GROUPS = {
|
|
|
57
57
|
"components"
|
|
58
58
|
]),
|
|
59
59
|
// Internal root alias (catch-all leftover @/ imports)
|
|
60
|
-
INTERNAL_ROOT: [
|
|
60
|
+
INTERNAL_ROOT: ["^@/.+$"],
|
|
61
61
|
// Relative parent imports then same-dir relatives
|
|
62
62
|
RELATIVE_PARENT: ["^\\.\\.(?!/?$)", "^\\.\\./?$"],
|
|
63
63
|
RELATIVE_SAME: ["^\\./(?=.*/)(?!/?$)", "^\\.(?!/?$)", "^\\./?$"],
|
package/dist/configs/next.js
CHANGED
|
@@ -57,7 +57,7 @@ var GROUPS = {
|
|
|
57
57
|
"components"
|
|
58
58
|
]),
|
|
59
59
|
// Internal root alias (catch-all leftover @/ imports)
|
|
60
|
-
INTERNAL_ROOT: [
|
|
60
|
+
INTERNAL_ROOT: ["^@/.+$"],
|
|
61
61
|
// Relative parent imports then same-dir relatives
|
|
62
62
|
RELATIVE_PARENT: ["^\\.\\.(?!/?$)", "^\\.\\./?$"],
|
|
63
63
|
RELATIVE_SAME: ["^\\./(?=.*/)(?!/?$)", "^\\.(?!/?$)", "^\\./?$"],
|
|
@@ -127,8 +127,14 @@ var typescriptRules = {
|
|
|
127
127
|
"@typescript-eslint/consistent-type-definitions": "off",
|
|
128
128
|
"@typescript-eslint/no-empty-function": "off",
|
|
129
129
|
"@typescript-eslint/array-type": "off",
|
|
130
|
-
"@typescript-eslint/consistent-type-imports": "error",
|
|
131
130
|
"@typescript-eslint/explicit-function-return-type": "error",
|
|
131
|
+
"@typescript-eslint/consistent-type-imports": [
|
|
132
|
+
"error",
|
|
133
|
+
{
|
|
134
|
+
prefer: "type-imports",
|
|
135
|
+
fixStyle: "separate-type-imports"
|
|
136
|
+
}
|
|
137
|
+
],
|
|
132
138
|
"@typescript-eslint/no-unused-vars": [
|
|
133
139
|
"error",
|
|
134
140
|
{
|
|
@@ -57,7 +57,7 @@ var GROUPS = {
|
|
|
57
57
|
"components"
|
|
58
58
|
]),
|
|
59
59
|
// Internal root alias (catch-all leftover @/ imports)
|
|
60
|
-
INTERNAL_ROOT: [
|
|
60
|
+
INTERNAL_ROOT: ["^@/.+$"],
|
|
61
61
|
// Relative parent imports then same-dir relatives
|
|
62
62
|
RELATIVE_PARENT: ["^\\.\\.(?!/?$)", "^\\.\\./?$"],
|
|
63
63
|
RELATIVE_SAME: ["^\\./(?=.*/)(?!/?$)", "^\\.(?!/?$)", "^\\./?$"],
|
|
@@ -127,8 +127,14 @@ var typescriptRules = {
|
|
|
127
127
|
"@typescript-eslint/consistent-type-definitions": "off",
|
|
128
128
|
"@typescript-eslint/no-empty-function": "off",
|
|
129
129
|
"@typescript-eslint/array-type": "off",
|
|
130
|
-
"@typescript-eslint/consistent-type-imports": "error",
|
|
131
130
|
"@typescript-eslint/explicit-function-return-type": "error",
|
|
131
|
+
"@typescript-eslint/consistent-type-imports": [
|
|
132
|
+
"error",
|
|
133
|
+
{
|
|
134
|
+
prefer: "type-imports",
|
|
135
|
+
fixStyle: "separate-type-imports"
|
|
136
|
+
}
|
|
137
|
+
],
|
|
132
138
|
"@typescript-eslint/no-unused-vars": [
|
|
133
139
|
"error",
|
|
134
140
|
{
|
package/dist/configs/react.js
CHANGED
|
@@ -57,7 +57,7 @@ var GROUPS = {
|
|
|
57
57
|
"components"
|
|
58
58
|
]),
|
|
59
59
|
// Internal root alias (catch-all leftover @/ imports)
|
|
60
|
-
INTERNAL_ROOT: [
|
|
60
|
+
INTERNAL_ROOT: ["^@/.+$"],
|
|
61
61
|
// Relative parent imports then same-dir relatives
|
|
62
62
|
RELATIVE_PARENT: ["^\\.\\.(?!/?$)", "^\\.\\./?$"],
|
|
63
63
|
RELATIVE_SAME: ["^\\./(?=.*/)(?!/?$)", "^\\.(?!/?$)", "^\\./?$"],
|
|
@@ -127,8 +127,14 @@ var typescriptRules = {
|
|
|
127
127
|
"@typescript-eslint/consistent-type-definitions": "off",
|
|
128
128
|
"@typescript-eslint/no-empty-function": "off",
|
|
129
129
|
"@typescript-eslint/array-type": "off",
|
|
130
|
-
"@typescript-eslint/consistent-type-imports": "error",
|
|
131
130
|
"@typescript-eslint/explicit-function-return-type": "error",
|
|
131
|
+
"@typescript-eslint/consistent-type-imports": [
|
|
132
|
+
"error",
|
|
133
|
+
{
|
|
134
|
+
prefer: "type-imports",
|
|
135
|
+
fixStyle: "separate-type-imports"
|
|
136
|
+
}
|
|
137
|
+
],
|
|
132
138
|
"@typescript-eslint/no-unused-vars": [
|
|
133
139
|
"error",
|
|
134
140
|
{
|
|
@@ -53,7 +53,7 @@ var GROUPS = {
|
|
|
53
53
|
"components"
|
|
54
54
|
]),
|
|
55
55
|
// Internal root alias (catch-all leftover @/ imports)
|
|
56
|
-
INTERNAL_ROOT: [
|
|
56
|
+
INTERNAL_ROOT: ["^@/.+$"],
|
|
57
57
|
// Relative parent imports then same-dir relatives
|
|
58
58
|
RELATIVE_PARENT: ["^\\.\\.(?!/?$)", "^\\.\\./?$"],
|
|
59
59
|
RELATIVE_SAME: ["^\\./(?=.*/)(?!/?$)", "^\\.(?!/?$)", "^\\./?$"],
|
|
@@ -92,8 +92,14 @@ var typescriptRules = {
|
|
|
92
92
|
"@typescript-eslint/consistent-type-definitions": "off",
|
|
93
93
|
"@typescript-eslint/no-empty-function": "off",
|
|
94
94
|
"@typescript-eslint/array-type": "off",
|
|
95
|
-
"@typescript-eslint/consistent-type-imports": "error",
|
|
96
95
|
"@typescript-eslint/explicit-function-return-type": "error",
|
|
96
|
+
"@typescript-eslint/consistent-type-imports": [
|
|
97
|
+
"error",
|
|
98
|
+
{
|
|
99
|
+
prefer: "type-imports",
|
|
100
|
+
fixStyle: "separate-type-imports"
|
|
101
|
+
}
|
|
102
|
+
],
|
|
97
103
|
"@typescript-eslint/no-unused-vars": [
|
|
98
104
|
"error",
|
|
99
105
|
{
|
package/dist/configs/vue.js
CHANGED
|
@@ -60,7 +60,7 @@ var GROUPS = {
|
|
|
60
60
|
"components"
|
|
61
61
|
]),
|
|
62
62
|
// Internal root alias (catch-all leftover @/ imports)
|
|
63
|
-
INTERNAL_ROOT: [
|
|
63
|
+
INTERNAL_ROOT: ["^@/.+$"],
|
|
64
64
|
// Relative parent imports then same-dir relatives
|
|
65
65
|
RELATIVE_PARENT: ["^\\.\\.(?!/?$)", "^\\.\\./?$"],
|
|
66
66
|
RELATIVE_SAME: ["^\\./(?=.*/)(?!/?$)", "^\\.(?!/?$)", "^\\./?$"],
|
|
@@ -130,8 +130,14 @@ var typescriptRules = {
|
|
|
130
130
|
"@typescript-eslint/consistent-type-definitions": "off",
|
|
131
131
|
"@typescript-eslint/no-empty-function": "off",
|
|
132
132
|
"@typescript-eslint/array-type": "off",
|
|
133
|
-
"@typescript-eslint/consistent-type-imports": "error",
|
|
134
133
|
"@typescript-eslint/explicit-function-return-type": "error",
|
|
134
|
+
"@typescript-eslint/consistent-type-imports": [
|
|
135
|
+
"error",
|
|
136
|
+
{
|
|
137
|
+
prefer: "type-imports",
|
|
138
|
+
fixStyle: "separate-type-imports"
|
|
139
|
+
}
|
|
140
|
+
],
|
|
135
141
|
"@typescript-eslint/no-unused-vars": [
|
|
136
142
|
"error",
|
|
137
143
|
{
|
package/dist/index.js
CHANGED
|
@@ -60,7 +60,7 @@ var GROUPS = {
|
|
|
60
60
|
"components"
|
|
61
61
|
]),
|
|
62
62
|
// Internal root alias (catch-all leftover @/ imports)
|
|
63
|
-
INTERNAL_ROOT: [
|
|
63
|
+
INTERNAL_ROOT: ["^@/.+$"],
|
|
64
64
|
// Relative parent imports then same-dir relatives
|
|
65
65
|
RELATIVE_PARENT: ["^\\.\\.(?!/?$)", "^\\.\\./?$"],
|
|
66
66
|
RELATIVE_SAME: ["^\\./(?=.*/)(?!/?$)", "^\\.(?!/?$)", "^\\./?$"],
|
|
@@ -130,8 +130,14 @@ var typescriptRules = {
|
|
|
130
130
|
"@typescript-eslint/consistent-type-definitions": "off",
|
|
131
131
|
"@typescript-eslint/no-empty-function": "off",
|
|
132
132
|
"@typescript-eslint/array-type": "off",
|
|
133
|
-
"@typescript-eslint/consistent-type-imports": "error",
|
|
134
133
|
"@typescript-eslint/explicit-function-return-type": "error",
|
|
134
|
+
"@typescript-eslint/consistent-type-imports": [
|
|
135
|
+
"error",
|
|
136
|
+
{
|
|
137
|
+
prefer: "type-imports",
|
|
138
|
+
fixStyle: "separate-type-imports"
|
|
139
|
+
}
|
|
140
|
+
],
|
|
135
141
|
"@typescript-eslint/no-unused-vars": [
|
|
136
142
|
"error",
|
|
137
143
|
{
|