diff --git a/.eslintrc.json b/.eslintrc.json deleted file mode 100644 index d87010f..0000000 --- a/.eslintrc.json +++ /dev/null @@ -1,21 +0,0 @@ -{ - "extends": [ - "eslint:recommended", - "plugin:prettier/recommended" - ], - "env": { - "es6": true, - "jest": true, - "node": true - }, - "plugins": [ - "prettier" - ], - "parserOptions": { - "ecmaVersion": 2018, - "sourceType": "module" - }, - "rules": { - "prettier/prettier": "error" - } -} diff --git a/eslint.config.js b/eslint.config.js new file mode 100644 index 0000000..f57a494 --- /dev/null +++ b/eslint.config.js @@ -0,0 +1,18 @@ +'use strict' + +const globals = require('globals') +const js = require('@eslint/js') +const prettier = require('eslint-plugin-prettier/recommended') + +module.exports = [ + { + languageOptions: { + globals: { + ...globals.node, + ...globals.jest, + }, + }, + }, + js.configs.recommended, + prettier, +] diff --git a/test/internal/watcherService.js b/test/internal/watcherService.js index b66f0ff..107f2c5 100644 --- a/test/internal/watcherService.js +++ b/test/internal/watcherService.js @@ -59,7 +59,7 @@ class AsyncHookContainer { const check = (t) => { try { return checkedTypes.includes(t) - } catch (err) { + } catch { return false } }