@cabloy/lint 4.0.0 → 4.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/api/eslint.js CHANGED
@@ -1,91 +1,4 @@
1
- const rules = {
2
- '@typescript-eslint/no-explicit-any': 'off',
3
- 'prefer-const': [
4
- 'error',
5
- {
6
- destructuring: 'all',
7
- ignoreReadBeforeAssign: true,
8
- },
9
- ],
10
- 'no-console': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
11
- 'no-debugger': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
12
- 'max-len': [
13
- 'error',
14
- {
15
- code: 120,
16
- ignoreComments: true,
17
- ignoreTrailingComments: true,
18
- ignoreUrls: true,
19
- ignoreStrings: true,
20
- ignoreTemplateLiterals: true,
21
- ignoreRegExpLiterals: true,
22
- },
23
- ],
24
- 'no-undef': [
25
- 'error',
26
- {
27
- typeof: false,
28
- },
29
- ],
30
- 'array-bracket-spacing': ['error', 'never'],
31
- 'no-empty': [
32
- 'error',
33
- {
34
- allowEmptyCatch: true,
35
- },
36
- ],
37
- 'no-empty-function': [
38
- 'error',
39
- {
40
- allow: [
41
- 'functions',
42
- 'arrowFunctions',
43
- 'generatorFunctions',
44
- 'methods',
45
- 'generatorMethods',
46
- 'getters',
47
- 'setters',
48
- 'constructors',
49
- 'asyncFunctions',
50
- 'asyncMethods',
51
- ],
52
- },
53
- ],
54
- 'no-constant-condition': [
55
- 'error',
56
- {
57
- checkLoops: false,
58
- },
59
- ],
60
- 'one-var-declaration-per-line': [0],
61
- 'space-before-function-paren': [
62
- 'error',
63
- {
64
- anonymous: 'always',
65
- named: 'never',
66
- asyncArrow: 'always',
67
- },
68
- ],
69
- 'generator-star-spacing': [0],
70
- 'newline-per-chained-call': [0],
71
- 'vue/multi-word-component-names': [0],
72
- '@typescript-eslint/no-var-requires': 'off',
73
- '@typescript-eslint/no-unused-vars': [
74
- 'error',
75
- {
76
- argsIgnorePattern: '^_',
77
- },
78
- ],
79
- '@typescript-eslint/no-this-alias': 'off',
80
- '@typescript-eslint/no-unsafe-declaration-merging': 'off',
81
- '@typescript-eslint/ban-ts-comment': [
82
- 'error',
83
- {
84
- 'ts-expect-error': 'allow-with-description',
85
- 'ts-ignore': 'allow-with-description',
86
- },
87
- ],
88
- };
1
+ const rules = require('../common/rules.js');
89
2
 
90
3
  module.exports = {
91
4
  parser: '@typescript-eslint/parser',
@@ -0,0 +1,90 @@
1
+ const rules = {
2
+ '@typescript-eslint/no-explicit-any': 'off',
3
+ 'prefer-const': [
4
+ 'error',
5
+ {
6
+ destructuring: 'all',
7
+ ignoreReadBeforeAssign: true,
8
+ },
9
+ ],
10
+ 'no-console': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
11
+ 'no-debugger': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
12
+ 'max-len': [
13
+ 'error',
14
+ {
15
+ code: 120,
16
+ ignoreComments: true,
17
+ ignoreTrailingComments: true,
18
+ ignoreUrls: true,
19
+ ignoreStrings: true,
20
+ ignoreTemplateLiterals: true,
21
+ ignoreRegExpLiterals: true,
22
+ },
23
+ ],
24
+ 'no-undef': [
25
+ 'error',
26
+ {
27
+ typeof: false,
28
+ },
29
+ ],
30
+ 'array-bracket-spacing': ['error', 'never'],
31
+ 'no-empty': [
32
+ 'error',
33
+ {
34
+ allowEmptyCatch: true,
35
+ },
36
+ ],
37
+ 'no-empty-function': [
38
+ 'error',
39
+ {
40
+ allow: [
41
+ 'functions',
42
+ 'arrowFunctions',
43
+ 'generatorFunctions',
44
+ 'methods',
45
+ 'generatorMethods',
46
+ 'getters',
47
+ 'setters',
48
+ 'constructors',
49
+ 'asyncFunctions',
50
+ 'asyncMethods',
51
+ ],
52
+ },
53
+ ],
54
+ 'no-constant-condition': [
55
+ 'error',
56
+ {
57
+ checkLoops: false,
58
+ },
59
+ ],
60
+ 'one-var-declaration-per-line': [0],
61
+ 'space-before-function-paren': [
62
+ 'error',
63
+ {
64
+ anonymous: 'always',
65
+ named: 'never',
66
+ asyncArrow: 'always',
67
+ },
68
+ ],
69
+ 'generator-star-spacing': [0],
70
+ 'newline-per-chained-call': [0],
71
+ 'vue/multi-word-component-names': [0],
72
+ '@typescript-eslint/no-var-requires': 'off',
73
+ '@typescript-eslint/no-unused-vars': [
74
+ 'error',
75
+ {
76
+ argsIgnorePattern: '^_',
77
+ },
78
+ ],
79
+ '@typescript-eslint/no-this-alias': 'off',
80
+ '@typescript-eslint/no-unsafe-declaration-merging': 'off',
81
+ '@typescript-eslint/ban-ts-comment': [
82
+ 'error',
83
+ {
84
+ 'ts-expect-error': 'allow-with-description',
85
+ 'ts-ignore': 'allow-with-description',
86
+ },
87
+ ],
88
+ };
89
+
90
+ module.exports = rules;
package/front/eslint.js CHANGED
@@ -1,91 +1,4 @@
1
- const rules = {
2
- '@typescript-eslint/no-explicit-any': 'off',
3
- 'prefer-const': [
4
- 'error',
5
- {
6
- destructuring: 'all',
7
- ignoreReadBeforeAssign: true,
8
- },
9
- ],
10
- 'no-console': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
11
- 'no-debugger': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
12
- 'max-len': [
13
- 'error',
14
- {
15
- code: 120,
16
- ignoreComments: true,
17
- ignoreTrailingComments: true,
18
- ignoreUrls: true,
19
- ignoreStrings: true,
20
- ignoreTemplateLiterals: true,
21
- ignoreRegExpLiterals: true,
22
- },
23
- ],
24
- 'no-undef': [
25
- 'error',
26
- {
27
- typeof: false,
28
- },
29
- ],
30
- 'array-bracket-spacing': ['error', 'never'],
31
- 'no-empty': [
32
- 'error',
33
- {
34
- allowEmptyCatch: true,
35
- },
36
- ],
37
- 'no-empty-function': [
38
- 'error',
39
- {
40
- allow: [
41
- 'functions',
42
- 'arrowFunctions',
43
- 'generatorFunctions',
44
- 'methods',
45
- 'generatorMethods',
46
- 'getters',
47
- 'setters',
48
- 'constructors',
49
- 'asyncFunctions',
50
- 'asyncMethods',
51
- ],
52
- },
53
- ],
54
- 'no-constant-condition': [
55
- 'error',
56
- {
57
- checkLoops: false,
58
- },
59
- ],
60
- 'one-var-declaration-per-line': [0],
61
- 'space-before-function-paren': [
62
- 'error',
63
- {
64
- anonymous: 'always',
65
- named: 'never',
66
- asyncArrow: 'always',
67
- },
68
- ],
69
- 'generator-star-spacing': [0],
70
- 'newline-per-chained-call': [0],
71
- 'vue/multi-word-component-names': [0],
72
- '@typescript-eslint/no-var-requires': 'off',
73
- '@typescript-eslint/no-unused-vars': [
74
- 'error',
75
- {
76
- argsIgnorePattern: '^_',
77
- },
78
- ],
79
- '@typescript-eslint/no-this-alias': 'off',
80
- '@typescript-eslint/no-unsafe-declaration-merging': 'off',
81
- '@typescript-eslint/ban-ts-comment': [
82
- 'error',
83
- {
84
- 'ts-expect-error': 'allow-with-description',
85
- 'ts-ignore': 'allow-with-description',
86
- },
87
- ],
88
- };
1
+ const rules = require('../common/rules.js');
89
2
 
90
3
  module.exports = {
91
4
  parser: '@typescript-eslint/parser',
package/front/prettier.js CHANGED
@@ -1,8 +1,3 @@
1
- module.exports = {
2
- semi: true,
3
- singleQuote: true,
4
- bracketSpacing: true,
5
- printWidth: 120,
6
- arrowParens: 'avoid',
7
- trailingComma: 'all',
8
- };
1
+ const config = require('../api/prettier.js');
2
+
3
+ module.exports = config;
package/package.json CHANGED
@@ -1,12 +1,13 @@
1
1
  {
2
2
  "name": "@cabloy/lint",
3
- "version": "4.0.0",
3
+ "version": "4.0.1",
4
4
  "description": "Node Style Guide for EggBorn/Cabloy.",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },
8
8
  "files": [
9
9
  "api",
10
+ "common",
10
11
  "front"
11
12
  ],
12
13
  "dependencies": {