aboutsummaryrefslogtreecommitdiffstats
path: root/packages/tslint-config
diff options
context:
space:
mode:
Diffstat (limited to 'packages/tslint-config')
-rw-r--r--packages/tslint-config/package.json2
-rw-r--r--packages/tslint-config/rules/booleanNamingRule.ts3
-rw-r--r--packages/tslint-config/rules/customNoMagicNumbersRule.ts2
-rw-r--r--packages/tslint-config/tslint.json3
4 files changed, 7 insertions, 3 deletions
diff --git a/packages/tslint-config/package.json b/packages/tslint-config/package.json
index a64feb836..452ac48a4 100644
--- a/packages/tslint-config/package.json
+++ b/packages/tslint-config/package.json
@@ -7,7 +7,7 @@
"description": "Lint rules related to 0xProject for TSLint",
"main": "tslint.json",
"scripts": {
- "watch": "tsc -w",
+ "watch_without_deps": "tsc -w",
"build": "tsc && copyfiles -u 2 './lib/monorepo_scripts/**/*' ./scripts",
"clean": "shx rm -rf lib scripts",
"lint": "tslint --project .",
diff --git a/packages/tslint-config/rules/booleanNamingRule.ts b/packages/tslint-config/rules/booleanNamingRule.ts
index a8e1dc390..6590f689b 100644
--- a/packages/tslint-config/rules/booleanNamingRule.ts
+++ b/packages/tslint-config/rules/booleanNamingRule.ts
@@ -3,7 +3,7 @@ import * as Lint from 'tslint';
import * as ts from 'typescript';
const VALID_BOOLEAN_PREFIXES = ['is', 'does', 'should', 'was', 'has', 'can', 'did', 'would', 'are'];
-
+// tslint:disable:no-unnecessary-type-assertion
export class Rule extends Lint.Rules.TypedRule {
public static FAILURE_STRING = `Boolean variable names should begin with: ${VALID_BOOLEAN_PREFIXES.join(', ')}`;
@@ -66,3 +66,4 @@ function handleBooleanNaming(
}
}
}
+// tslint:enable:no-unnecessary-type-assertion
diff --git a/packages/tslint-config/rules/customNoMagicNumbersRule.ts b/packages/tslint-config/rules/customNoMagicNumbersRule.ts
index e358221eb..0a565b2e6 100644
--- a/packages/tslint-config/rules/customNoMagicNumbersRule.ts
+++ b/packages/tslint-config/rules/customNoMagicNumbersRule.ts
@@ -2,6 +2,7 @@ import * as Lint from 'tslint';
import { isPrefixUnaryExpression } from 'tsutils';
import * as ts from 'typescript';
+// tslint:disable:no-unnecessary-type-assertion
/**
* A modified version of the no-magic-numbers rule that allows for magic numbers
* when instantiating a BigNumber instance.
@@ -74,3 +75,4 @@ class CustomNoMagicNumbersWalker extends Lint.AbstractWalker<Set<string>> {
}
// tslint:enable:no-non-null-assertion
}
+// tslint:enable:no-unnecessary-type-assertion
diff --git a/packages/tslint-config/tslint.json b/packages/tslint-config/tslint.json
index 77a1f41cc..680883f47 100644
--- a/packages/tslint-config/tslint.json
+++ b/packages/tslint-config/tslint.json
@@ -7,6 +7,7 @@
"async-suffix": true,
"boolean-naming": true,
"no-switch-case-fall-through": true,
+ "switch-default": true,
"await-promise": true,
"custom-no-magic-numbers": [true, 0, 1, 2, 3, -1],
"binary-expression-operand-order": true,
@@ -28,7 +29,6 @@
"interface-name": false,
"interface-over-type-literal": true,
"linebreak-style": [true, "LF"],
- "max-classes-per-file": false,
"max-classes-per-file": [true, 1],
"max-line-length": false,
"max-file-line-count": [true, 500],
@@ -45,6 +45,7 @@
"no-parameter-reassignment": true,
"no-redundant-jsdoc": true,
"no-return-await": true,
+ "no-unused-variable": true,
"no-string-throw": true,
"no-submodule-imports": false,
"no-unnecessary-type-assertion": true,