repositories
/
poolifier.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
docs: add links to examples
[poolifier.git]
/
.eslintrc.js
diff --git
a/.eslintrc.js
b/.eslintrc.js
index 7448b400d0814fad77f4338920cccba9799afce0..c5784c0f286cac8f39b921950a6ae437e2a88e8e 100644
(file)
--- a/
.eslintrc.js
+++ b/
.eslintrc.js
@@
-1,15
+1,14
@@
-// @ts-check
const { defineConfig } = require('eslint-define-config')
module.exports = defineConfig({
root: true,
env: {
const { defineConfig } = require('eslint-define-config')
module.exports = defineConfig({
root: true,
env: {
- es202
1
: true,
+ es202
2
: true,
node: true,
mocha: true
},
parserOptions: {
node: true,
mocha: true
},
parserOptions: {
- ecmaVersion: 202
1
,
+ ecmaVersion: 202
2
,
sourceType: 'module'
},
plugins: ['promise', 'spellcheck'],
sourceType: 'module'
},
plugins: ['promise', 'spellcheck'],
@@
-18,54
+17,74
@@
module.exports = defineConfig({
'plugin:import/recommended',
'plugin:promise/recommended'
],
'plugin:import/recommended',
'plugin:promise/recommended'
],
+ settings: {
+ 'import/resolver': {
+ typescript: {
+ project: './tsconfig.eslint.json'
+ }
+ }
+ },
rules: {
rules: {
- 'no-void': 'off',
-
'sort-imports': [
'sort-imports': [
- '
warn
',
+ '
error
',
{
{
- ignoreMemberSort: true,
ignoreDeclarationSort: true
}
],
ignoreDeclarationSort: true
}
],
+ 'import/order': 'error',
'spellcheck/spell-checker': [
'warn',
{
skipWords: [
'spellcheck/spell-checker': [
'warn',
{
skipWords: [
+ 'benoit',
'benny',
'browserslist',
'builtins',
'christopher',
'cjs',
'benny',
'browserslist',
'builtins',
'christopher',
'cjs',
+ 'cloneable',
'comparator',
'cpu',
'cpus',
'ctx',
'comparator',
'cpu',
'cpus',
'ctx',
+ 'deprecations',
+ 'dequeue',
+ 'dequeued',
'ecma',
'ecma',
+ 'elu',
+ 'enqueue',
'enum',
'enum',
+ 'errored',
+ 'esm',
'fibonacci',
'fs',
'inheritDoc',
'jsdoc',
'microjob',
'fibonacci',
'fs',
'inheritDoc',
'jsdoc',
'microjob',
+ 'mjs',
'num',
'os',
'num',
'os',
+ 'perf',
'piscina',
'piscina',
+ 'pnpm',
'poolifier',
'poolify',
'readonly',
'poolifier',
'poolify',
'readonly',
- '
serializabl
e',
+ '
resiz
e',
'sinon',
'threadjs',
'threadwork',
'sinon',
'threadjs',
'threadwork',
+ 'tinypool',
'tsconfig',
'tsdoc',
'typedoc',
'unlink',
'tsconfig',
'tsdoc',
'typedoc',
'unlink',
+ 'unref',
'unregister',
'utf8',
'unregister',
'utf8',
- 'workerpool'
+ 'workerpool',
+ 'wwr'
],
skipIfMatch: ['^@.*', '^plugin:.*']
}
],
skipIfMatch: ['^@.*', '^plugin:.*']
}
@@
-77,27
+96,20
@@
module.exports = defineConfig({
plugins: ['@typescript-eslint', 'eslint-plugin-tsdoc'],
parser: '@typescript-eslint/parser',
parserOptions: {
plugins: ['@typescript-eslint', 'eslint-plugin-tsdoc'],
parser: '@typescript-eslint/parser',
parserOptions: {
- project: './tsconfig.json'
+ project: './tsconfig.
eslint.
json'
},
extends: [
},
extends: [
- 'plugin:@typescript-eslint/eslint-recommended',
'plugin:@typescript-eslint/recommended',
'plugin:@typescript-eslint/recommended-requiring-type-checking',
'plugin:@typescript-eslint/recommended',
'plugin:@typescript-eslint/recommended-requiring-type-checking',
- '
standard-with-
typescript',
- '
plugin:import/
typescript'
+ '
plugin:import/
typescript',
+ '
standard-with-
typescript'
],
rules: {
],
rules: {
- // We have some intentionally empty functions
- '@typescript-eslint/no-empty-function': 'off',
-
'@typescript-eslint/no-inferrable-types': [
'error',
{ ignoreProperties: true }
],
'@typescript-eslint/no-inferrable-types': [
'error',
{ ignoreProperties: true }
],
-
- 'no-useless-constructor': 'off',
-
- 'tsdoc/syntax': 'error'
+ 'tsdoc/syntax': 'warn'
}
},
{
}
},
{
@@
-106,13
+118,16
@@
module.exports = defineConfig({
'import/no-unresolved': 'off',
'@typescript-eslint/no-unsafe-argument': 'off',
'@typescript-eslint/no-unsafe-call': 'off',
'import/no-unresolved': 'off',
'@typescript-eslint/no-unsafe-argument': 'off',
'@typescript-eslint/no-unsafe-call': 'off',
- '@typescript-eslint/no-unsafe-assignment': 'off'
+ '@typescript-eslint/no-unsafe-assignment': 'off',
+ '@typescript-eslint/no-unsafe-member-access': 'off',
+ '@typescript-eslint/no-unnecessary-type-assertion': 'off',
+ '@typescript-eslint/restrict-template-expressions': 'off'
}
},
{
}
},
{
- files: ['**/*.js'],
+ files: ['**/*.js'
, '**/*.mjs'
],
plugins: ['jsdoc'],
plugins: ['jsdoc'],
- extends: ['plugin:n/recommended', '
standard', 'plugin:jsdoc/recommende
d']
+ extends: ['plugin:n/recommended', '
plugin:jsdoc/recommended', 'standar
d']
},
{
files: ['tests/**/*.js'],
},
{
files: ['tests/**/*.js'],
@@
-127,7
+142,7
@@
module.exports = defineConfig({
}
},
{
}
},
{
- files: ['benchmarks/**/*.js'],
+ files: ['benchmarks/**/*.js'
, 'benchmarks/**/*.mjs'
],
rules: {
'jsdoc/require-jsdoc': 'off'
}
rules: {
'jsdoc/require-jsdoc': 'off'
}
@@
-138,6
+153,13
@@
module.exports = defineConfig({
'n/no-missing-require': 'off'
}
},
'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: {
{
files: ['examples/**/*.js'],
rules: {