From f84e1f113e9fcba68cae30e40ca8187b529d24f4 Mon Sep 17 00:00:00 2001 From: Filipe Silva Date: Tue, 7 Mar 2017 14:08:18 +0000 Subject: [PATCH] fix(@angular/cli): fix TS2.1 typeroots (#5251) TS-Node with TypeScript 2.1+ does not infer `typeRoots`, so we need to list them explicitely in the root tsconfig. Issue for TS-Node: https://github.com/TypeStrong/ts-node/issues/283 Fix #5082 --- docs/documentation/stories/rc-update.md | 3 +++ packages/@angular/cli/blueprints/ng/files/tsconfig.json | 3 +++ 2 files changed, 6 insertions(+) diff --git a/docs/documentation/stories/rc-update.md b/docs/documentation/stories/rc-update.md index cfb5ec2345c6..c366384e8360 100644 --- a/docs/documentation/stories/rc-update.md +++ b/docs/documentation/stories/rc-update.md @@ -273,6 +273,9 @@ There is an additional root-level `tsconfig.json` that is used for IDE integrati "emitDecoratorMetadata": true, "experimentalDecorators": true, "target": "es5", + "typeRoots": [ + "node_modules/@types" + ], "lib": [ "es2016", "dom" diff --git a/packages/@angular/cli/blueprints/ng/files/tsconfig.json b/packages/@angular/cli/blueprints/ng/files/tsconfig.json index 7a9d9e8c58ab..1f9b55851bec 100644 --- a/packages/@angular/cli/blueprints/ng/files/tsconfig.json +++ b/packages/@angular/cli/blueprints/ng/files/tsconfig.json @@ -8,6 +8,9 @@ "emitDecoratorMetadata": true, "experimentalDecorators": true, "target": "es5", + "typeRoots": [ + "node_modules/@types" + ], "lib": [ "es2016", "dom"