fix(ivy): allow building router with ngtsc (#24862)

This commit adds the ivy-local tag to //packages/router. Since the
router depends on //packages/upgrade, it makes that package
compatible with ngtsc as well.

PR Close #24862
This commit is contained in:
Alex Rickabaugh 2018-07-06 09:31:46 -07:00 committed by Victor Berchet
parent f58f3dc07a
commit 8a5cd2200a
4 changed files with 4 additions and 2 deletions

View File

@ -30,6 +30,7 @@ ng_package(
entry_point = "packages/router/index.js",
tags = [
"ivy-jit",
"ivy-local",
"release-with-framework",
],
deps = [

View File

@ -27,6 +27,7 @@ ng_package(
entry_point = "packages/upgrade/index.js",
tags = [
"ivy-jit",
"ivy-local",
"release-with-framework",
],
deps = [

View File

@ -571,7 +571,7 @@ export class UpgradeAdapter {
};
// At this point we have ng1 injector and we have prepared
// ng1 components to be upgraded, we now can bootstrap ng2.
@NgModule(ngModule)
@NgModule({jit: true, ...ngModule})
class DynamicNgUpgradeModule {
constructor() {}
ngDoBootstrap() {}

View File

@ -45,7 +45,7 @@ export class UpgradeNg1ComponentAdapterBuilder {
// TODO(tbosch): find or file a bug against TypeScript for this.
const directive = {selector: selector, inputs: this.inputsRename, outputs: this.outputsRename};
@Directive(directive)
@Directive({jit: true, ...directive})
class MyClass {
// TODO(issue/24571): remove '!'.
directive !: angular.IDirective;