forked from benhason1/nestjs-http-promise
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #406 from furality/spr/main/689361d1
build(deps): update eslint
- Loading branch information
Showing
7 changed files
with
1,082 additions
and
1,841 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,32 +1,28 @@ | ||
version: 2 | ||
updates: | ||
- package-ecosystem: "npm" | ||
directory: "/" | ||
- package-ecosystem: 'npm' | ||
directory: '/' | ||
schedule: | ||
interval: "daily" | ||
interval: 'daily' | ||
versioning-strategy: increase | ||
open-pull-requests-limit: 10 | ||
commit-message: | ||
prefix: "build(deps)" | ||
prefix-development: "build(deps-dev)" | ||
prefix: 'build(deps)' | ||
prefix-development: 'build(deps-dev)' | ||
groups: | ||
dependencies: | ||
patterns: | ||
- "*" | ||
exclude-patterns: | ||
- eslint | ||
- eslint-plugin-sonarjs | ||
- eslint-plugin-unused-imports | ||
- '*' | ||
|
||
- package-ecosystem: "github-actions" | ||
directory: "/" | ||
- package-ecosystem: 'github-actions' | ||
directory: '/' | ||
schedule: | ||
interval: "daily" | ||
interval: 'daily' | ||
open-pull-requests-limit: 10 | ||
commit-message: | ||
prefix: "ci(action)" | ||
prefix-development: "ci(dev-action)" | ||
prefix: 'ci(action)' | ||
prefix-development: 'ci(dev-action)' | ||
groups: | ||
dependencies: | ||
patterns: | ||
- "*" | ||
dependencies: | ||
patterns: | ||
- '*' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
import eslint from '@eslint/js'; | ||
import eslintPluginPrettierRecommended from 'eslint-plugin-prettier/recommended'; | ||
import simpleImportSort from 'eslint-plugin-simple-import-sort'; | ||
import sonarjs from 'eslint-plugin-sonarjs'; | ||
// @ts-ignore no types for some reason | ||
import unusedImports from 'eslint-plugin-unused-imports'; | ||
import tseslint from 'typescript-eslint'; | ||
|
||
export default tseslint.config( | ||
eslint.configs.recommended, | ||
...tseslint.configs.strictTypeChecked, | ||
...tseslint.configs.stylisticTypeChecked, | ||
// @ts-ignore doesn't like this | ||
eslintPluginPrettierRecommended, | ||
sonarjs.configs.recommended, | ||
{ | ||
languageOptions: { | ||
parserOptions: { | ||
projectService: true, | ||
// @ts-ignore incorrectly things node can't handle this | ||
tsconfigRootDir: import.meta.dirname, | ||
}, | ||
}, | ||
plugins: { | ||
'simple-import-sort': simpleImportSort, | ||
'unused-imports': unusedImports, | ||
}, | ||
rules: { | ||
'simple-import-sort/imports': 'error', | ||
'simple-import-sort/exports': 'error', | ||
eqeqeq: 'error', | ||
'no-lonely-if': 'error', | ||
'no-multi-assign': 'error', | ||
'@typescript-eslint/no-shadow': 'error', | ||
'no-useless-return': 'error', | ||
'no-useless-rename': 'error', | ||
'object-shorthand': 'error', | ||
'one-var-declaration-per-line': 'error', | ||
'prefer-object-spread': 'error', | ||
'no-unreachable-loop': 'error', | ||
'no-template-curly-in-string': 'error', | ||
'default-case-last': 'error', | ||
'no-array-constructor': 'error', | ||
'no-else-return': 'error', | ||
'no-negated-condition': 'error', | ||
'array-callback-return': 'error', | ||
'@typescript-eslint/consistent-type-definitions': 'error', | ||
'@typescript-eslint/ban-ts-comment': 'error', | ||
'@typescript-eslint/no-unnecessary-condition': 'error', | ||
'@typescript-eslint/no-extraneous-class': 'off', | ||
'@typescript-eslint/prefer-nullish-coalescing': 'error', | ||
'@typescript-eslint/no-import-type-side-effects': 'error', | ||
'@typescript-eslint/consistent-type-imports': 'error', | ||
'@typescript-eslint/consistent-type-exports': 'error', | ||
curly: 'error', | ||
'no-console': 'error', | ||
quotes: [ | ||
'error', | ||
'single', | ||
{ | ||
avoidEscape: true, | ||
}, | ||
], | ||
'prefer-template': 'error', | ||
'@typescript-eslint/return-await': ['error', 'always'], | ||
'unused-imports/no-unused-imports': 'error', | ||
}, | ||
}, | ||
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.