@naturalcycles/dev-lib 13.13.0 → 13.14.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.
@@ -384,5 +384,35 @@ module.exports = {
384
384
  'unicorn/prefer-export-from': 0, // breaks auto-imports in IntelliJ Idea
385
385
  'unicorn/no-await-expression-member': 0, // some cases are better as-is
386
386
  'unicorn/prefer-json-parse-buffer': 0, // typescript doesn't allow it
387
+ 'no-constructor-return': 2,
388
+ // 'no-promise-executor-return': 2,
389
+ 'no-self-compare': 2,
390
+ 'no-unreachable-loop': 2,
391
+ // 'func-style': [2, 'declaration'],
392
+ 'logical-assignment-operators': [
393
+ 2,
394
+ 'always',
395
+ {
396
+ enforceForIfStatements: true,
397
+ },
398
+ ],
399
+ 'max-params': [2, { max: 4 }],
400
+ 'no-else-return': 2,
401
+ 'no-sequences': 2,
402
+ 'no-useless-concat': 2,
403
+ '@typescript-eslint/ban-tslint-comment': 2,
404
+ // '@typescript-eslint/explicit-function-return-type': [2, {
405
+ // allowTypedFunctionExpressions: true,
406
+ // allowHigherOrderFunctions: true,
407
+ // }],
408
+ '@typescript-eslint/method-signature-style': [2, 'method'],
409
+ '@typescript-eslint/no-unnecessary-boolean-literal-compare': 2,
410
+ // '@typescript-eslint/no-unnecessary-condition': [2, {
411
+ // allowConstantLoopConditions: true,
412
+ // }],
413
+ '@typescript-eslint/prefer-includes': 2,
414
+ '@typescript-eslint/prefer-optional-chain': 2,
415
+ '@typescript-eslint/prefer-string-starts-ends-with': 2,
416
+ '@typescript-eslint/prefer-ts-expect-error': 2,
387
417
  },
388
418
  }
@@ -14,6 +14,7 @@ function getTSConfigPathScripts() {
14
14
  return [`./scripts/tsconfig.json`].find(p => fs.existsSync(p)) || `${paths_cnst_1.scriptsDir}/tsconfig.json`;
15
15
  }
16
16
  exports.getTSConfigPathScripts = getTSConfigPathScripts;
17
+ // eslint-disable-next-line max-params
17
18
  async function runESLint(dir, eslintConfigPath, tsconfigPath, extensions = ['ts', 'tsx', 'vue'], fix = true) {
18
19
  if (!fs.existsSync(dir))
19
20
  return; // faster to bail-out like this
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@naturalcycles/dev-lib",
3
- "version": "13.13.0",
3
+ "version": "13.14.0",
4
4
  "scripts": {
5
5
  "prepare": "husky install",
6
6
  "tsn-debug": "tsn testScript.ts",