angular/packages/compiler-cli/src/ngtsc
JoostK 1de49ba369 refactor(ivy): consistently translate types to ts.TypeNode (#34021)
The compiler has a translation mechanism to convert from an Angular
`Type` to a `ts.TypeNode`, as appropriate. Prior to this change, it
would translate certain Angular expressions into their value equivalent
in TypeScript, instead of the correct type equivalent. This was possible
as the `ExpressionVisitor` interface is not strictly typed, with `any`s
being used for return values.

For example, a literal object was translated into a
`ts.ObjectLiteralExpression`, containing `ts.PropertyAssignment` nodes
as its entries. This has worked without issues as their printed
representation is identical, however it was incorrect from a semantic
point of view. Instead, a `ts.TypeLiteralNode` is created with
`ts.PropertySignature` as its members, which corresponds with the type
declaration of an object literal.

PR Close #34021
2020-01-06 11:06:07 -08:00
..
annotations feat(ivy): error in ivy when inheriting a ctor from an undecorated base (#34460) 2019-12-18 15:04:49 -08:00
cycles perf(ivy): use module resolution cache (#34332) 2019-12-12 14:06:37 -08:00
diagnostics feat(ivy): error in ivy when inheriting a ctor from an undecorated base (#34460) 2019-12-18 15:04:49 -08:00
entry_point refactor(ivy): implement a virtual file-system layer in ngtsc + ngcc (#30921) 2019-06-25 16:25:24 -07:00
file_system test(ivy): support chdir() on the compiler's filesystem abstraction (#33828) 2019-11-19 12:41:24 -08:00
imports refactor(ivy): move NgModule declaration checks to the 'scope' package (#34460) 2019-12-18 15:04:49 -08:00
incremental perf(ivy): reuse prior analysis work during incremental builds (#34288) 2019-12-12 13:11:45 -08:00
indexer fix(ivy): support abstract directives in template type checking (#33131) 2019-10-24 12:44:30 -07:00
metadata feat(ivy): throw compilation error when providing undecorated classes (#34460) 2019-12-18 15:04:49 -08:00
modulewithproviders refactor(ivy): include generic type for ModuleWithProviders in .d.ts files (#34235) 2019-12-10 16:34:47 -08:00
partial_evaluator refactor(compiler-cli): avoid unnecessarily calling getSourceFile() twice in PartialEvaluator (#34441) 2019-12-17 14:38:16 -08:00
perf refactor(ivy): implement a virtual file-system layer in ngtsc + ngcc (#30921) 2019-06-25 16:25:24 -07:00
reflection fix(ngcc): handle new __spreadArrays tslib helper (#33617) 2019-11-06 19:43:07 +00:00
routing perf(ivy): use module resolution cache (#34332) 2019-12-12 14:06:37 -08:00
scope fix(ivy): don't produce template diagnostics when scope is invalid (#34460) 2019-12-18 15:04:49 -08:00
shims refactor(ivy): move analysis side effects into a register phase (#34288) 2019-12-12 13:11:45 -08:00
switch build: rules_nodejs 0.26.0 & use @npm instead of @ngdeps now that downstream angular build uses angular bundles (#28871) 2019-02-28 12:06:36 -08:00
testing refactor(ivy): implement a virtual file-system layer in ngtsc + ngcc (#30921) 2019-06-25 16:25:24 -07:00
transform refactor(ivy): consistently translate types to ts.TypeNode (#34021) 2020-01-06 11:06:07 -08:00
translator refactor(ivy): consistently translate types to ts.TypeNode (#34021) 2020-01-06 11:06:07 -08:00
typecheck refactor(ivy): consistently translate types to ts.TypeNode (#34021) 2020-01-06 11:06:07 -08:00
util perf(ivy): support simple generic type constraints in local type ctors (#34021) 2020-01-06 11:06:07 -08:00
program.ts perf(ivy): support simple generic type constraints in local type ctors (#34021) 2020-01-06 11:06:07 -08:00
resource_loader.ts fix(ivy): handle rooted resource paths correctly (#31511) 2019-07-11 11:42:33 -04:00
synthetic_files_compiler_host.ts feat: add support for TypeScript 3.3 (and drop older versions) (#29004) 2019-03-13 10:38:37 -07:00
tsc_plugin.ts refactor(ivy): use ClassDeclaration in more ReflectionHost methods (#29209) 2019-03-21 22:20:23 +00:00