@cookshack/eslint-config 1.0.0 → 1.2.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.
@@ -0,0 +1 @@
1
+ npm run check
package/dist/index.cjs CHANGED
@@ -66,6 +66,7 @@ exports.rules = {
66
66
  'no-negated-condition': 'error',
67
67
  'no-redeclare': 'error',
68
68
  'no-sequences': 'error',
69
+ 'no-sparse-arrays': 'error',
69
70
  'no-tabs': 'error',
70
71
  'no-trailing-spaces': 'error',
71
72
  'no-undef': 'error',
@@ -73,6 +74,7 @@ exports.rules = {
73
74
  'no-unused-vars': 'error',
74
75
  'no-var': 'error',
75
76
  'object-curly-spacing': [ 'error', 'always' ],
77
+ 'object-shorthand': [ 'error', 'always' ],
76
78
  quotes: [ 'error', 'single', { avoidEscape: true } ],
77
79
  semi: [ 'error', 'never' ]
78
80
  //'vars-on-top': [ 'error' ], // want version for let
package/dist/index.js CHANGED
@@ -62,6 +62,7 @@ rules = {
62
62
  'no-negated-condition': 'error',
63
63
  'no-redeclare': 'error',
64
64
  'no-sequences': 'error',
65
+ 'no-sparse-arrays': 'error',
65
66
  'no-tabs': 'error',
66
67
  'no-trailing-spaces': 'error',
67
68
  'no-undef': 'error',
@@ -69,6 +70,7 @@ rules = {
69
70
  'no-unused-vars': 'error',
70
71
  'no-var': 'error',
71
72
  'object-curly-spacing': [ 'error', 'always' ],
73
+ 'object-shorthand': [ 'error', 'always' ],
72
74
  quotes: [ 'error', 'single', { avoidEscape: true } ],
73
75
  semi: [ 'error', 'never' ]
74
76
  //'vars-on-top': [ 'error' ], // want version for let
@@ -86,8 +88,8 @@ languageOptions = {
86
88
  };
87
89
 
88
90
  var index = [ { ignores: [ 'TAGS.mjs' ] },
89
- { languageOptions: languageOptions,
90
- plugins: plugins,
91
- rules: rules } ];
91
+ { languageOptions,
92
+ plugins,
93
+ rules } ];
92
94
 
93
95
  export { index as default, languageOptions, plugins, rules };
package/index.js CHANGED
@@ -62,6 +62,7 @@ rules = {
62
62
  'no-negated-condition': 'error',
63
63
  'no-redeclare': 'error',
64
64
  'no-sequences': 'error',
65
+ 'no-sparse-arrays': 'error',
65
66
  'no-tabs': 'error',
66
67
  'no-trailing-spaces': 'error',
67
68
  'no-undef': 'error',
@@ -69,6 +70,7 @@ rules = {
69
70
  'no-unused-vars': 'error',
70
71
  'no-var': 'error',
71
72
  'object-curly-spacing': [ 'error', 'always' ],
73
+ 'object-shorthand': [ 'error', 'always' ],
72
74
  quotes: [ 'error', 'single', { avoidEscape: true } ],
73
75
  semi: [ 'error', 'never' ]
74
76
  //'vars-on-top': [ 'error' ], // want version for let
@@ -87,6 +89,6 @@ languageOptions = {
87
89
 
88
90
  export
89
91
  default [ { ignores: [ 'TAGS.mjs' ] },
90
- { languageOptions: languageOptions,
91
- plugins: plugins,
92
- rules: rules } ]
92
+ { languageOptions,
93
+ plugins,
94
+ rules } ]
package/package.json CHANGED
@@ -1,12 +1,13 @@
1
1
  {
2
2
  "name": "@cookshack/eslint-config",
3
- "version": "1.0.0",
3
+ "version": "1.2.0",
4
4
  "description": "ESLint config for Cookshack projects",
5
5
  "homepage": "https://git.sr.ht/~mattmundell/eslint-config",
6
6
  "type": "module",
7
7
  "scripts": {
8
+ "check": "npx eslint --no-warn-ignored -f ./formatter.js -c ./index.js *.js",
8
9
  "test": "echo \"Error: no test specified\" && exit 1",
9
- "prepare": "rollup -c"
10
+ "prepare": "husky && rollup -c"
10
11
  },
11
12
  "main": "dist/index.cjs",
12
13
  "module": "dist/index.js",
@@ -25,6 +26,7 @@
25
26
  "globals": "^15.10.0"
26
27
  },
27
28
  "devDependencies": {
29
+ "husky": "^9.1.7",
28
30
  "rollup": "^4.27.2"
29
31
  }
30
32
  }