feat(ivy): strip all Angular decorators in compiled classes (#24677)

Previously ngtsc removed the class-level decorators (@Component,
etc) but left all the ancillary decorators (@Input, @Optional,
etc).

This changes the transform to descend into the members of decorated
classes and remove any Angular decorators, not just the class-level
ones.

PR Close #24677
This commit is contained in:
Alex Rickabaugh
2018-06-20 15:57:40 -07:00
committed by Miško Hevery
parent 104d30507a
commit fc4dc35426
2 changed files with 126 additions and 7 deletions

View File

@ -132,7 +132,7 @@ export class NgtscProgram implements api.Program {
options: this.options,
emitOnlyDtsFiles: false, writeFile,
customTransformers: {
before: [ivyTransformFactory(compilation, coreImportsFrom)],
before: [ivyTransformFactory(compilation, reflector, coreImportsFrom)],
},
});
return emitResult;