You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Hydro/.eslintrc.yaml

50 lines
1.2 KiB
YAML

root: true
extends:
- '@hydrooj/eslint-config'
ignorePatterns:
- public/**/*.js
- packages/ui-default
overrides:
- files:
- '**/public/**/*.{ts,tsx,page.js}'
rules:
'@typescript-eslint/indent':
- warn
- 2
'@typescript-eslint/no-invalid-this': 0
env:
browser: true
es6: true
jquery: true
globals:
UiContext: true
UserContext: true
externalModules: true
LOCALES: true
LANGS: true
rules:
'@typescript-eslint/no-invalid-this': 1
simple-import-sort/imports:
- warn
- groups:
- ["^\\u0000"]
-
- "^(assert|buffer|child_process|cluster|console|constants|crypto|dgram|dns|domain|events|fs|http|https|module|net|os|path|punycode|querystring|readline|repl|stream|string_decoder|sys|timers|tls|tty|url|util|vm|zlib|freelist|v8|process|async_hooks|http2|perf_hooks)(/.*|$)"
- "^(?!@?hydrooj)(@?\\w.+)"
- "^@?hydrooj"
- "^"
- "^\\."
settings:
import/parsers:
'@typescript-eslint/parser':
- .ts
- .js
- .jsx
import/resolver:
typescript:
alwaysTryTypes: true
parserOptions:
sourceType: module
# project:
# - './tsconfig.json'
# - './packages/**/tsconfig.json'