From ba175be41f3bc5120c2439ab1cffd71f8065d465 Mon Sep 17 00:00:00 2001 From: Charles Lyding <19598772+clydin@users.noreply.github.com> Date: Fri, 10 Jul 2020 12:41:35 -0400 Subject: [PATCH] fix(compiler-cli): match wrapHost parameter types within plugin interface (#38004) The `TscPlugin` interface using a type of `ts.CompilerHost&Partial` for the `host` parameter of the `wrapHost` method. However, prior to this change, the interface implementing `NgTscPlugin` class used a type of `ts.CompilerHost&UnifiedModulesHost` for the parameter. This change corrects the inconsistency and allows `UnifiedModulesHost` members to be optional when using the `NgtscPlugin`. PR Close #38004 --- packages/compiler-cli/src/ngtsc/tsc_plugin.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/compiler-cli/src/ngtsc/tsc_plugin.ts b/packages/compiler-cli/src/ngtsc/tsc_plugin.ts index 7c87be7f22..54c6238521 100644 --- a/packages/compiler-cli/src/ngtsc/tsc_plugin.ts +++ b/packages/compiler-cli/src/ngtsc/tsc_plugin.ts @@ -79,7 +79,7 @@ export class NgTscPlugin implements TscPlugin { } wrapHost( - host: ts.CompilerHost&UnifiedModulesHost, inputFiles: readonly string[], + host: ts.CompilerHost&Partial, inputFiles: readonly string[], options: ts.CompilerOptions): PluginCompilerHost { // TODO(alxhub): Eventually the `wrapHost()` API will accept the old `ts.Program` (if one is // available). When it does, its `ts.SourceFile`s need to be re-tagged to enable proper