Skip to content

Commit

Permalink
chore: update ts rules
Browse files Browse the repository at this point in the history
  • Loading branch information
jinasonlin committed Apr 1, 2019
1 parent fa8b2eb commit 3418838
Showing 1 changed file with 23 additions and 4 deletions.
27 changes: 23 additions & 4 deletions rules/typescript.js
Original file line number Diff line number Diff line change
@@ -1,19 +1,38 @@
module.exports = {
plugins: ['@typescript-eslint'],
rules: {
// 暂时采用 ESLint 内建规则或编译
/**
* 下列规则基于 ESLint Core 实现
* 部分规则暂时可采用 ESLint 内建规则及编译时的静态检查
*/
// '@typescript-eslint/indent': [
// 'error',
// 2,
// {
// SwitchCase: 1,
// },
// ],
// '@typescript-eslint/camelcase': 'off',
// camelcase: 'off',
// '@typescript-eslint/camelcase': [
// 'error',
// {
// properties: 'never',
// },
// ],
// '@typescript-eslint/no-array-constructor': 'off',
// '@typescript-eslint/no-unused-vars': 'off',
// '@typescript-eslint/no-useless-constructor': 'error',
// '@typescript-eslint/no-use-before-define': 'off',
'no-unused-vars': 'off',
'@typescript-eslint/no-unused-vars': [
'warn',
{
vars: 'all',
args: 'after-used',
caughtErrors: 'none',
ignoreRestSiblings: true,
},
],
'@typescript-eslint/no-useless-constructor': 'error',


'@typescript-eslint/adjacent-overload-signatures': 'error',
'@typescript-eslint/array-type': 'off',
Expand Down

0 comments on commit 3418838

Please sign in to comment.