diff --git a/src/compiler/program.ts b/src/compiler/program.ts index 74abd84b436..e536111a489 100644 --- a/src/compiler/program.ts +++ b/src/compiler/program.ts @@ -1734,6 +1734,7 @@ namespace ts { if (!newSourceFile) { return StructureIsReused.Not; } + newSourceFile.impliedNodeFormat = sourceFileOptions.impliedNodeFormat; newSourceFile.packageJsonLocations = sourceFileOptions.packageJsonLocations?.length ? sourceFileOptions.packageJsonLocations : undefined; newSourceFile.packageJsonScope = sourceFileOptions.packageJsonScope; @@ -2968,6 +2969,7 @@ namespace ts { file.path = path; file.resolvedPath = toPath(fileName); file.originalFileName = originalFileName; + file.impliedNodeFormat = sourceFileOptions.impliedNodeFormat; file.packageJsonLocations = sourceFileOptions.packageJsonLocations?.length ? sourceFileOptions.packageJsonLocations : undefined; file.packageJsonScope = sourceFileOptions.packageJsonScope; addFileIncludeReason(file, reason);