@jiakun-zhao/eslint-config 1.1.2 → 1.1.4

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.
Files changed (2) hide show
  1. package/dist/index.cjs +11 -2
  2. package/package.json +2 -1
package/dist/index.cjs CHANGED
@@ -30,6 +30,7 @@ const ignorePatterns = [
30
30
 
31
31
  const index = {
32
32
  plugins: [
33
+ "unicorn",
33
34
  "unused-imports"
34
35
  ],
35
36
  extends: [
@@ -121,12 +122,20 @@ const index = {
121
122
  "key-spacing": ["error", { beforeColon: false, afterColon: true }],
122
123
  "switch-colon-spacing": ["error", { before: false, after: true }],
123
124
  "space-before-function-paren": ["error", "never"],
124
- "@typescript-eslint/type-annotation-spacing": ["error", { before: false, after: true }],
125
+ "arrow-spacing": ["error", { before: true, after: true }],
126
+ "@typescript-eslint/type-annotation-spacing": ["error", {
127
+ before: false,
128
+ after: true,
129
+ overrides: { arrow: { before: true, after: true } }
130
+ }],
131
+ "@typescript-eslint/space-before-blocks": ["error", "always"],
125
132
  // quote
126
133
  "quote-props": ["error", "consistent-as-needed"],
127
134
  // comma
128
135
  "comma-dangle": ["error", "always-multiline"],
129
- "@typescript-eslint/comma-dangle": ["error", "always-multiline"]
136
+ "@typescript-eslint/comma-dangle": ["error", "always-multiline"],
137
+ // unicorn
138
+ "unicorn/prefer-node-protocol": "error"
130
139
  }
131
140
  };
132
141
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jiakun-zhao/eslint-config",
3
- "version": "1.1.2",
3
+ "version": "1.1.4",
4
4
  "description": "Jiakun's ESLint config.",
5
5
  "keywords": [
6
6
  "eslint-config"
@@ -24,6 +24,7 @@
24
24
  "eslint-plugin-n": "^16.0.1",
25
25
  "eslint-plugin-promise": "^6.1.1",
26
26
  "eslint-plugin-react": "^7.32.2",
27
+ "eslint-plugin-unicorn": "^48.0.0",
27
28
  "eslint-plugin-unused-imports": "^3.0.0",
28
29
  "eslint-plugin-vue": "^9.15.1"
29
30
  },