From b3c66dc702bdb118a37f873e7270277f8a2ac84e Mon Sep 17 00:00:00 2001 From: ssube Date: Fri, 1 Nov 2019 08:02:32 -0500 Subject: [PATCH] fix(rules/tsconfig): flatten target-lib using data refs --- config/tsconfig.json | 3 --- rules/tsconfig.yml | 46 ++++---------------------------------------- 2 files changed, 4 insertions(+), 45 deletions(-) diff --git a/config/tsconfig.json b/config/tsconfig.json index 2943802..77c5f53 100755 --- a/config/tsconfig.json +++ b/config/tsconfig.json @@ -15,13 +15,10 @@ ], "module": "es6", "moduleResolution": "node", - "noImplicitAny": true, "noImplicitReturns": true, - "noImplicitThis": true, "outDir": "../out", "sourceMap": true, "strict": true, - "strictNullChecks": true, "target": "es2017", "types": [ "jsonpath-plus", diff --git a/rules/tsconfig.yml b/rules/tsconfig.yml index 7de0b65..d583ade 100644 --- a/rules/tsconfig.yml +++ b/rules/tsconfig.yml @@ -33,6 +33,7 @@ rules: check: not: anyOf: + # from https://www.typescriptlang.org/docs/handbook/compiler-options.html - required: [alwaysStrict] - required: [noImplicitAny] - required: [noImplicitThis] @@ -75,47 +76,8 @@ rules: lib: contains: type: string - const: esnext + const: + $data: "2/target" target: type: string - const: esnext - - properties: - lib: - contains: - type: string - const: es2017 - target: - type: string - const: es2017 - - properties: - lib: - contains: - type: string - const: es2016 - target: - type: string - const: es2016 - - properties: - lib: - contains: - type: string - enum: [es2015, es6] - target: - type: string - enum: [es2015, es6] - - properties: - lib: - contains: - type: string - const: es5 - target: - type: string - const: es5 - - properties: - lib: - contains: - type: string - const: es3 - target: - type: string - const: es3 \ No newline at end of file + enum: [esnext, es2017, es2016, es5, es3] \ No newline at end of file