aboutsummaryrefslogtreecommitdiffhomepage
path: root/eslint.config.js
diff options
context:
space:
mode:
Diffstat (limited to 'eslint.config.js')
-rw-r--r--eslint.config.js36
1 files changed, 18 insertions, 18 deletions
diff --git a/eslint.config.js b/eslint.config.js
index 7ac6782..3bca729 100644
--- a/eslint.config.js
+++ b/eslint.config.js
@@ -1,16 +1,16 @@
1import globals from "globals"; 1import globals from 'globals'
2import js from "@eslint/js"; 2import js from '@eslint/js'
3import importPlugin from "eslint-plugin-import"; 3import importPlugin from 'eslint-plugin-import'
4import promisePlugin from "eslint-plugin-promise"; 4import promisePlugin from 'eslint-plugin-promise'
5import nodePlugin from "eslint-plugin-node"; 5import nodePlugin from 'eslint-plugin-node'
6import jsdoc from 'eslint-plugin-jsdoc'; 6import jsdoc from 'eslint-plugin-jsdoc'
7 7
8export default [ 8export default [
9 js.configs.recommended, 9 js.configs.recommended,
10 { 10 {
11 languageOptions: { 11 languageOptions: {
12 ecmaVersion: 2022, 12 ecmaVersion: 2022,
13 sourceType: "module", 13 sourceType: 'module',
14 globals: { 14 globals: {
15 ...globals.browser, 15 ...globals.browser,
16 ...globals.node 16 ...globals.node
@@ -19,31 +19,31 @@ export default [
19 plugins: { 19 plugins: {
20 import: importPlugin, 20 import: importPlugin,
21 promise: promisePlugin, 21 promise: promisePlugin,
22 node: nodePlugin, 22 node: nodePlugin
23 }, 23 },
24 rules: { 24 rules: {
25 'no-unused-vars': ['warn', { 25 'no-unused-vars': ['warn', {
26 'varsIgnorePattern': '^_', 26 varsIgnorePattern: '^_',
27 "argsIgnorePattern": "^_", 27 argsIgnorePattern: '^_',
28 "caughtErrorsIgnorePattern": "^ignore|_", 28 caughtErrorsIgnorePattern: '^ignore|_'
29 }], 29 }],
30 'import/no-unresolved': 'error', 30 'import/no-unresolved': 'error',
31 'no-console': ["error", { allow: ["info", "warn", "error"] }], 31 'no-console': ['error', { allow: ['info', 'warn', 'error'] }],
32 'eqeqeq': ['error', 'always'], 32 eqeqeq: ['error', 'always'],
33 // 'curly': ['warn', 'multi'], 33 // 'curly': ['warn', 'multi'],
34 'prefer-const': 'error', 34 'prefer-const': 'error',
35 'no-var': 'error', 35 'no-var': 'error',
36 'array-callback-return': 'error', 36 'array-callback-return': 'error',
37 'no-unexpected-multiline': 'warn', 37 'no-unexpected-multiline': 'warn'
38 }, 38 }
39 }, 39 },
40 { 40 {
41 files: ['src/*js'], 41 files: ['src/*js'],
42 plugins: { 42 plugins: {
43 jsdoc, 43 jsdoc
44 }, 44 },
45 rules: { 45 rules: {
46 'jsdoc/require-description': 'warn' 46 'jsdoc/require-description': 'warn'
47 } 47 }
48 }, 48 }
49]; 49]