mirror of
https://github.com/angular/angular.git
synced 2026-09-14 13:54:52 +08:00
refactor(migrations): expose angular compiler options to signal input migration (#57347)
Instead of exposing just the `ts.CompilerOptions`, we should expose the actual Angular compiler options throuhgout the signal input migration. This will be useful for parsing templates, in cases of JIT-opted components. PR Close #57347
This commit is contained in:
committed by
Andrew Kushnir
parent
52673e6420
commit
310a0e0eda
@@ -17,6 +17,7 @@ ts_library(
|
||||
"//packages/compiler-cli/src/ngtsc/annotations/common",
|
||||
"//packages/compiler-cli/src/ngtsc/annotations/directive",
|
||||
"//packages/compiler-cli/src/ngtsc/core",
|
||||
"//packages/compiler-cli/src/ngtsc/core:api",
|
||||
"//packages/compiler-cli/src/ngtsc/diagnostics",
|
||||
"//packages/compiler-cli/src/ngtsc/file_system",
|
||||
"//packages/compiler-cli/src/ngtsc/imports",
|
||||
|
||||
+1
-1
@@ -55,7 +55,7 @@ export function convertToSignalInput(
|
||||
}
|
||||
|
||||
const strictPropertyInitialization =
|
||||
!!host.tsOptions.strict || !!host.tsOptions.strictPropertyInitialization;
|
||||
!!host.options.strict || !!host.options.strictPropertyInitialization;
|
||||
const inputArgs: ts.Expression[] = [];
|
||||
const typeArguments: ts.TypeNode[] = [];
|
||||
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
|
||||
import path from 'path';
|
||||
import ts from 'typescript';
|
||||
import {NgCompilerOptions} from '../../../../../compiler-cli/src/ngtsc/core/api';
|
||||
|
||||
/**
|
||||
* A migration host is in practice a container object that
|
||||
@@ -20,7 +21,7 @@ export class MigrationHost {
|
||||
constructor(
|
||||
public projectDir: string,
|
||||
public isMigratingCore: boolean,
|
||||
public tsOptions: ts.CompilerOptions,
|
||||
public options: NgCompilerOptions,
|
||||
sourceFiles: readonly ts.SourceFile[],
|
||||
) {
|
||||
this._sourceFiles = new WeakSet(sourceFiles);
|
||||
|
||||
Reference in New Issue
Block a user