X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=.eslintrc.js;h=e421cd282cf758417b1609b6a887f4335619b708;hb=refs%2Ftags%2Fv2.6.10;hp=1d6840072e7dcc07e92d2586af15623120b927f8;hpb=d21911e6a11e8b38213135284c8b06c87d3bb722;p=poolifier.git diff --git a/.eslintrc.js b/.eslintrc.js index 1d684007..e421cd28 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -1,4 +1,3 @@ -// @ts-check const { defineConfig } = require('eslint-define-config') module.exports = defineConfig({ @@ -18,14 +17,21 @@ module.exports = defineConfig({ 'plugin:import/recommended', 'plugin:promise/recommended' ], + settings: { + 'import/resolver': { + typescript: { + project: './tsconfig.eslint.json' + } + } + }, rules: { 'sort-imports': [ - 'warn', + 'error', { - ignoreMemberSort: true, ignoreDeclarationSort: true } ], + 'import/order': 'error', 'spellcheck/spell-checker': [ 'warn', @@ -37,40 +43,47 @@ module.exports = defineConfig({ 'builtins', 'christopher', 'cjs', + 'cloneable', 'comparator', 'cpu', 'cpus', 'ctx', 'deprecations', + 'dequeue', + 'dequeued', 'ecma', + 'elu', + 'enqueue', 'enum', + 'errored', 'esm', 'fibonacci', 'fs', - 'hrtime', 'inheritDoc', 'jsdoc', 'microjob', 'mjs', 'num', 'os', + 'perf', 'piscina', 'pnpm', 'poolifier', 'poolify', 'readonly', 'resize', - 'serializable', 'sinon', 'threadjs', 'threadwork', + 'tinypool', 'tsconfig', 'tsdoc', 'typedoc', 'unlink', 'unregister', 'utf8', - 'workerpool' + 'workerpool', + 'wwr' ], skipIfMatch: ['^@.*', '^plugin:.*'] } @@ -82,7 +95,7 @@ module.exports = defineConfig({ plugins: ['@typescript-eslint', 'eslint-plugin-tsdoc'], parser: '@typescript-eslint/parser', parserOptions: { - project: './tsconfig.json' + project: './tsconfig.eslint.json' }, extends: [ 'plugin:@typescript-eslint/eslint-recommended', @@ -102,7 +115,6 @@ module.exports = defineConfig({ { files: ['examples/typescript/**/*.ts'], rules: { - 'import/no-unresolved': 'off', '@typescript-eslint/no-unsafe-argument': 'off', '@typescript-eslint/no-unsafe-call': 'off', '@typescript-eslint/no-unsafe-assignment': 'off' @@ -126,7 +138,7 @@ module.exports = defineConfig({ } }, { - files: ['benchmarks/**/*.js'], + files: ['benchmarks/**/*.js', 'benchmarks/**/*.mjs'], rules: { 'jsdoc/require-jsdoc': 'off' } @@ -137,6 +149,13 @@ module.exports = defineConfig({ 'n/no-missing-require': 'off' } }, + { + files: ['benchmarks/versus-external-pools/**/*.mjs'], + rules: { + 'n/no-missing-import': 'off', + 'import/no-unresolved': 'off' + } + }, { files: ['examples/**/*.js'], rules: {