@zendeskgarden/eslint-config 42.0.0 → 43.0.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zendeskgarden/eslint-config",
3
- "version": "42.0.0",
3
+ "version": "43.0.0",
4
4
  "description": "Garden ESLint config",
5
5
  "license": "Apache-2.0",
6
6
  "author": "Zendesk Garden <garden@zendesk.com>",
@@ -19,12 +19,14 @@
19
19
  "format": "prettier-package-json --write",
20
20
  "lint": "eslint eslint.config.js index.js plugins/*.js rules/*.js --max-warnings 0",
21
21
  "prepare": "husky",
22
+ "start": "npm exec @eslint/config-inspector",
22
23
  "tag": "[ `git rev-parse --abbrev-ref HEAD` = 'main' ] && standard-version --no-verify",
23
24
  "test": "npm run format && npm run lint && git diff --quiet"
24
25
  },
25
26
  "dependencies": {
26
27
  "@babel/eslint-parser": "7.24.7",
27
28
  "@eslint/compat": "1.1.0",
29
+ "eslint-plugin-deprecation": "3.0.0",
28
30
  "eslint-plugin-jest": "28.6.0",
29
31
  "eslint-plugin-jsx-a11y": "6.9.0",
30
32
  "eslint-plugin-n": "17.9.0",
@@ -39,6 +41,9 @@
39
41
  },
40
42
  "devDependencies": {
41
43
  "@babel/core": "7.24.7",
44
+ "@eslint/config-inspector": "0.5.0",
45
+ "@zendeskgarden/scripts": "2.3.0",
46
+ "envalid": "8.0.0",
42
47
  "eslint": "9.5.0",
43
48
  "husky": "9.0.11",
44
49
  "jest": "29.7.0",
@@ -5,9 +5,11 @@
5
5
  * found at http://www.apache.org/licenses/LICENSE-2.0.
6
6
  */
7
7
 
8
+ import deprecationPlugin from 'eslint-plugin-deprecation';
8
9
  import eslintLayoutFormatting from '../rules/layout-formatting.js';
9
10
  import eslintPossibleProblems from '../rules/possible-problems.js';
10
11
  import eslintSuggestions from '../rules/suggestions.js';
12
+ import { fixupPluginRules } from '@eslint/compat';
11
13
  import tseslint from 'typescript-eslint';
12
14
 
13
15
  const eslintRules = {
@@ -18,7 +20,8 @@ const eslintRules = {
18
20
 
19
21
  export default {
20
22
  plugins: {
21
- '@typescript-eslint': tseslint.plugin
23
+ '@typescript-eslint': tseslint.plugin,
24
+ deprecation: fixupPluginRules(deprecationPlugin)
22
25
  },
23
26
  languageOptions: {
24
27
  parser: tseslint.parser,
@@ -160,6 +163,8 @@ export default {
160
163
  // enforces unbound methods are called with their expected scope
161
164
  '@typescript-eslint/unbound-method': 2,
162
165
  // requires type annotation of catch() parameter remain unknown
163
- '@typescript-eslint/use-unknown-in-catch-callback-variable': 2
166
+ '@typescript-eslint/use-unknown-in-catch-callback-variable': 2,
167
+ // disallow usage of deprecated APIs
168
+ 'deprecation/deprecation': 'warn'
164
169
  }
165
170
  };