mirror of
https://github.com/Terncode/pixel.horse.git
synced 2026-09-24 21:55:52 +02:00
Replace tslint with eslint
This commit is contained in:
+122
@@ -0,0 +1,122 @@
|
|||||||
|
module.exports = {
|
||||||
|
env: {
|
||||||
|
browser: true,
|
||||||
|
es6: true,
|
||||||
|
node: true
|
||||||
|
},
|
||||||
|
extends: [
|
||||||
|
'eslint:recommended',
|
||||||
|
'plugin:@typescript-eslint/recommended'
|
||||||
|
],
|
||||||
|
parser: '@typescript-eslint/parser',
|
||||||
|
parserOptions: {
|
||||||
|
ecmaVersion: 12
|
||||||
|
},
|
||||||
|
plugins: [
|
||||||
|
'@typescript-eslint'
|
||||||
|
],
|
||||||
|
rules: {
|
||||||
|
indent: [
|
||||||
|
'warn',
|
||||||
|
'tab',
|
||||||
|
{
|
||||||
|
SwitchCase: 1,
|
||||||
|
ignoredNodes: ['ConditionalExpression'],
|
||||||
|
},
|
||||||
|
],
|
||||||
|
quotes: [
|
||||||
|
'warn',
|
||||||
|
'single',
|
||||||
|
{ allowTemplateLiterals: true, avoidEscape: true },
|
||||||
|
],
|
||||||
|
'linebreak-style': [
|
||||||
|
'warn',
|
||||||
|
'unix'
|
||||||
|
],
|
||||||
|
'max-len': ['warn', { 'code': 200 }],
|
||||||
|
semi: [
|
||||||
|
'warn',
|
||||||
|
'always'
|
||||||
|
],
|
||||||
|
radix: [
|
||||||
|
'error',
|
||||||
|
],
|
||||||
|
'@typescript-eslint/no-empty-interface': [
|
||||||
|
'warn',
|
||||||
|
{
|
||||||
|
'allowSingleExtends': true
|
||||||
|
}
|
||||||
|
],
|
||||||
|
'camelcase': 'warn',
|
||||||
|
'no-trailing-spaces': 'warn',
|
||||||
|
'no-unused-labels': 'error',
|
||||||
|
'keyword-spacing': ['warn', { 'before': true, 'after': true }],
|
||||||
|
'no-new-wrappers': 'error',
|
||||||
|
'no-debugger': 'error',
|
||||||
|
'no-eval': 'error',
|
||||||
|
'no-redeclare': 'off',
|
||||||
|
'no-underscore-dangle': 'off',
|
||||||
|
'no-multiple-empty-lines': [
|
||||||
|
'warn',
|
||||||
|
{
|
||||||
|
'max': 2
|
||||||
|
}
|
||||||
|
],
|
||||||
|
'no-caller': 'error',
|
||||||
|
'no-console': [
|
||||||
|
'error',
|
||||||
|
{
|
||||||
|
'allow': [
|
||||||
|
'log',
|
||||||
|
'warn',
|
||||||
|
'dir',
|
||||||
|
'timeLog',
|
||||||
|
'assert',
|
||||||
|
'clear',
|
||||||
|
'count',
|
||||||
|
'countReset',
|
||||||
|
'group',
|
||||||
|
'groupEnd',
|
||||||
|
'table',
|
||||||
|
'dirxml',
|
||||||
|
'error',
|
||||||
|
'groupCollapsed',
|
||||||
|
'Console',
|
||||||
|
'profile',
|
||||||
|
'profileEnd',
|
||||||
|
'timeStamp',
|
||||||
|
'context'
|
||||||
|
]
|
||||||
|
}
|
||||||
|
],
|
||||||
|
'eol-last': 'error',
|
||||||
|
'eqeqeq': [
|
||||||
|
'error',
|
||||||
|
'smart'
|
||||||
|
],
|
||||||
|
'guard-for-in': 'error',
|
||||||
|
'no-case-declarations': 'off',
|
||||||
|
'no-sparse-arrays': 'off',
|
||||||
|
'no-empty-pattern': 'off',
|
||||||
|
'no-cond-assign': 'off',
|
||||||
|
'no-unused-vars': 'off',
|
||||||
|
'prefer-const': 'off',
|
||||||
|
'id-denylist': 'off',
|
||||||
|
'id-match': 'off',
|
||||||
|
'no-empty': 'off',
|
||||||
|
'@typescript-eslint/explicit-module-boundary-types': 'off',
|
||||||
|
'@typescript-eslint/triple-slash-reference': 'off',
|
||||||
|
'@typescript-eslint/no-non-null-assertion': 'off',
|
||||||
|
'@typescript-eslint/no-empty-function': 'off',
|
||||||
|
'@typescript-eslint/no-var-requires': 'off',
|
||||||
|
'@typescript-eslint/no-explicit-any': 'off',
|
||||||
|
'@typescript-eslint/ban-ts-comment': 'off',
|
||||||
|
'@typescript-eslint/ban-types' : 'off',
|
||||||
|
'no-mixed-spaces-and-tabs' : 'off',
|
||||||
|
'no-constant-condition': 'off',
|
||||||
|
'@typescript-eslint/no-unused-vars': [
|
||||||
|
'warn',
|
||||||
|
{ argsIgnorePattern: '^_' }
|
||||||
|
],
|
||||||
|
}
|
||||||
|
};
|
||||||
Generated
+7598
-4557
File diff suppressed because it is too large
Load Diff
@@ -105,6 +105,8 @@
|
|||||||
"@types/uws": "^0.13.2",
|
"@types/uws": "^0.13.2",
|
||||||
"@types/webgl2": "0.0.5",
|
"@types/webgl2": "0.0.5",
|
||||||
"@types/yargs": "^13.0.2",
|
"@types/yargs": "^13.0.2",
|
||||||
|
"@typescript-eslint/eslint-plugin": "^2.34.0",
|
||||||
|
"@typescript-eslint/parser": "^2.34.0",
|
||||||
"ag-psd": "^6.2.0",
|
"ag-psd": "^6.2.0",
|
||||||
"ag-sockets": "^4.7.0",
|
"ag-sockets": "^4.7.0",
|
||||||
"angular2-template-loader": "^0.6.2",
|
"angular2-template-loader": "^0.6.2",
|
||||||
@@ -125,6 +127,12 @@
|
|||||||
"del": "^5.1.0",
|
"del": "^5.1.0",
|
||||||
"delta-e": "0.0.7",
|
"delta-e": "0.0.7",
|
||||||
"errorhandler": "^1.5.1",
|
"errorhandler": "^1.5.1",
|
||||||
|
"eslint": "^5.16.0",
|
||||||
|
"eslint-config-google": "^0.14.0",
|
||||||
|
"eslint-config-standard": "^17.1.0",
|
||||||
|
"eslint-plugin-import": "^2.32.0",
|
||||||
|
"eslint-plugin-node": "^11.1.0",
|
||||||
|
"eslint-plugin-promise": "^6.1.1",
|
||||||
"express": "^4.17.1",
|
"express": "^4.17.1",
|
||||||
"express-brute": "^1.0.1",
|
"express-brute": "^1.0.1",
|
||||||
"express-session": "^1.16.2",
|
"express-session": "^1.16.2",
|
||||||
|
|||||||
-77
@@ -1,77 +0,0 @@
|
|||||||
{
|
|
||||||
"rules": {
|
|
||||||
"ban": [
|
|
||||||
true,
|
|
||||||
"name",
|
|
||||||
"length",
|
|
||||||
"focus"
|
|
||||||
],
|
|
||||||
"class-name": true,
|
|
||||||
"forin": true,
|
|
||||||
"indent": [
|
|
||||||
true,
|
|
||||||
"tabs"
|
|
||||||
],
|
|
||||||
"label-position": true,
|
|
||||||
"no-arg": true,
|
|
||||||
"no-console": [
|
|
||||||
true,
|
|
||||||
"debug",
|
|
||||||
"info",
|
|
||||||
"time",
|
|
||||||
"timeEnd",
|
|
||||||
"trace"
|
|
||||||
],
|
|
||||||
"adjacent-overload-signatures": true,
|
|
||||||
"no-internal-module": true,
|
|
||||||
"no-namespace": true,
|
|
||||||
"no-construct": true,
|
|
||||||
"no-consecutive-blank-lines": [
|
|
||||||
true,
|
|
||||||
2
|
|
||||||
],
|
|
||||||
"no-debugger": true,
|
|
||||||
"no-duplicate-variable": true,
|
|
||||||
"no-eval": true,
|
|
||||||
"no-trailing-whitespace": true,
|
|
||||||
"linebreak-style": [
|
|
||||||
true,
|
|
||||||
"LF"
|
|
||||||
],
|
|
||||||
"one-line": [
|
|
||||||
true,
|
|
||||||
"check-open-brace",
|
|
||||||
"check-catch",
|
|
||||||
"check-whitespace"
|
|
||||||
],
|
|
||||||
"radix": true,
|
|
||||||
"semicolon": [
|
|
||||||
true,
|
|
||||||
"always"
|
|
||||||
],
|
|
||||||
"triple-equals": [
|
|
||||||
true,
|
|
||||||
"allow-null-check"
|
|
||||||
],
|
|
||||||
"variable-name": false,
|
|
||||||
"whitespace": [
|
|
||||||
true,
|
|
||||||
"check-branch",
|
|
||||||
"check-decl",
|
|
||||||
"check-operator",
|
|
||||||
"check-module",
|
|
||||||
"check-separator",
|
|
||||||
"check-type"
|
|
||||||
],
|
|
||||||
"eofline": true,
|
|
||||||
"quotemark": [
|
|
||||||
true,
|
|
||||||
"single",
|
|
||||||
"avoid-escape"
|
|
||||||
],
|
|
||||||
"array-type": [
|
|
||||||
true,
|
|
||||||
"array"
|
|
||||||
]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
Reference in New Issue
Block a user