From cbe5e9b178bb122525cda6f2dfcc692f96af8ebd Mon Sep 17 00:00:00 2001 From: Juan Leyva Date: Thu, 25 Jan 2018 13:02:29 +0100 Subject: [PATCH] MOBILE-2356 ts: Add linter rule for types --- tslint.json | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/tslint.json b/tslint.json index 31511782a..ec7b715c0 100644 --- a/tslint.json +++ b/tslint.json @@ -102,7 +102,14 @@ "semicolon": [true, "always"], "variable-name": [true, "ban-keywords", "check-format", "allow-leading-underscore"], "whitespace": [true, "check-branch", "check-decl", "check-operator", "check-module", "check-separator", "check-type", - "check-typecast", "check-type-operator", "check-preblock"] + "check-typecast", "check-type-operator", "check-preblock"], + "ban-types": [ + true, + ["Boolean", "Use 'boolean' instead."], + ["Number", "Use 'number' instead."], + ["String", "Use 'string' instead."], + ["Object", "Use {} instead."] + ] }, "rulesDirectory": [ "node_modules/tslint-eslint-rules/dist/rules"