control-center/.eslintrc.js
Rinat Arsaev c0b4167e2f
FRONTEND-560: NPMv7, FE Core ESLint Config (#266)
* upd eslint

* eslint fix

* 1

* ExecStateType

* 1

* NAMESPACES

* sort members

* 1

* 1

* name

* ifels

* 1

* ClaimStatus

* interface ClaimInfo

* interface

* sort

* token

* 1

* 1

* 1

* args

* 1

* 1

* 1

* ord

* ContractModificationName

* sups

* 1

* sup

* sup @typescript-eslint/member-ordering

* Revert "ContractModificationName"

This reverts commit 82177c58

* 1

* 1

* 1

* generateId

* 1

* 1

* 1

* Array.isArray

* terminalActionTypes

* 1

* JSON PARSER

* 1

* 1

* 1

* 1

* 1

* fix imports

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* ifelse

* PredicateType

* 1

* 1

* 1

* 1

* yes no

* icons

* 1

* 1

* 1

* 1

* 1

* ContractorId

* type

* 1

* 1

* TerminalType

* ExecResultType

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* payoutRole

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* createDsl

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* rem import isString from 'lodash-es/isString';

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 1

* 2147

* fix import groups

* bump

* lint errors

* format

* --config

* rm

* bump thrift-ts & npmV7

* lint

* bump image build

* upd build_utils

* rm @typescript-eslint/eslint-plugin

* sort tasks

* rename to test

* upd tasks

* add ignore

* gen-*

* concrete gen

* upd ignore
2021-05-13 14:42:10 +03:00

67 lines
2.2 KiB
JavaScript

const rules = require('@rbkmoney/eslint-plugin/lib/rules');
const baseTsRules = {
...rules.createImportOrderRule({
internalPathsPattern: '@cc/**',
}),
// TODO: pretenders for error
'@typescript-eslint/no-unsafe-call': 'warn',
'@typescript-eslint/no-unsafe-member-access': 'warn',
'@typescript-eslint/no-unsafe-assignment': 'warn',
'@typescript-eslint/no-unsafe-return': 'warn',
'@typescript-eslint/no-misused-promises': 'warn',
'@typescript-eslint/unbound-method': 'warn',
'@typescript-eslint/restrict-plus-operands': 'warn',
'@typescript-eslint/restrict-template-expressions': 'warn',
};
module.exports = {
root: true,
parser: '@typescript-eslint/parser',
ignorePatterns: ['**/gen-*/**/*'],
overrides: [
{
files: ['*.ts'],
parserOptions: {
project: ['tsconfig.json', 'e2e/tsconfig.json'],
createDefaultProgram: true,
},
extends: [
'plugin:@rbkmoney/typescript',
'plugin:@rbkmoney/angular',
'plugin:@rbkmoney/lodash',
'plugin:@rbkmoney/prettier',
],
rules: {
...baseTsRules,
...rules.createAngularSelectorRules({ prefix: 'cc' }),
// TODO: pretenders for error
'@typescript-eslint/no-floating-promises': 'warn',
},
},
{
files: ['*.spec.ts'],
parserOptions: {
project: ['tsconfig.json', 'e2e/tsconfig.json'],
createDefaultProgram: true,
},
extends: [
'plugin:@rbkmoney/typescript',
'plugin:@rbkmoney/angular',
'plugin:@rbkmoney/jasmine',
'plugin:@rbkmoney/lodash',
'plugin:@rbkmoney/prettier',
],
rules: baseTsRules,
},
{
files: ['*.html'],
extends: ['plugin:@angular-eslint/template/recommended'],
rules: {
// TODO: pretenders for error
'@angular-eslint/template/no-negated-async': 'warn',
},
},
],
};