diff --git a/build.sh b/build.sh index 7b373e0aba..5f3a6e7f90 100755 --- a/build.sh +++ b/build.sh @@ -85,7 +85,7 @@ do if [[ ${PACKAGE} == "router-deprecated" ]]; then echo "====== (esm)COMPILING: \$(npm bin)/tsc -p ${SRCDIR}/tsconfig-es2015.json =====" - $(npm bin)/tsc -p ${SRCDIR}/tsconfig-es2015.json + $(npm bin)/tsc --emitDecoratorMetadata -p ${SRCDIR}/tsconfig-es2015.json else echo "====== (esm)COMPILING: $TSC -p ${SRCDIR}/tsconfig-es2015.json =====" $TSC -p ${SRCDIR}/tsconfig-es2015.json diff --git a/modules/@angular/common/tsconfig-es2015.json b/modules/@angular/common/tsconfig-es2015.json index 9cc18d6dcf..eb3aafe295 100644 --- a/modules/@angular/common/tsconfig-es2015.json +++ b/modules/@angular/common/tsconfig-es2015.json @@ -1,12 +1,8 @@ { - "angularCompilerOptions": { - "skipTemplateCodegen": true - }, "compilerOptions": { "baseUrl": ".", "declaration": true, "stripInternal": true, - "emitDecoratorMetadata": true, "experimentalDecorators": true, "module": "es2015", "moduleResolution": "node", diff --git a/modules/@angular/common/tsconfig-es5.json b/modules/@angular/common/tsconfig-es5.json index b11904fff7..1ddbe55386 100644 --- a/modules/@angular/common/tsconfig-es5.json +++ b/modules/@angular/common/tsconfig-es5.json @@ -1,12 +1,8 @@ { - "angularCompilerOptions": { - "skipTemplateCodegen": true - }, "compilerOptions": { "baseUrl": ".", "declaration": true, "stripInternal": true, - "emitDecoratorMetadata": true, "experimentalDecorators": true, "module": "commonjs", "moduleResolution": "node", diff --git a/modules/@angular/compiler-cli/integrationtest/src/a/multiple_components.ts b/modules/@angular/compiler-cli/integrationtest/src/a/multiple_components.ts index fa2450e477..35624d77d9 100644 --- a/modules/@angular/compiler-cli/integrationtest/src/a/multiple_components.ts +++ b/modules/@angular/compiler-cli/integrationtest/src/a/multiple_components.ts @@ -22,7 +22,7 @@ export class HasCustomDecorator { // Verify that custom decorators have metadata collected, eg Ionic export function Page(c: any): (f: Function) => void { - return c; + return NotADirective; } @Page({template: 'Ionic template'}) diff --git a/modules/@angular/compiler-cli/tsconfig-es5.json b/modules/@angular/compiler-cli/tsconfig-es5.json index 4a0ff6f020..ee6b249db3 100644 --- a/modules/@angular/compiler-cli/tsconfig-es5.json +++ b/modules/@angular/compiler-cli/tsconfig-es5.json @@ -1,7 +1,4 @@ { - "angularCompilerOptions": { - "skipTemplateCodegen": true - }, "compilerOptions": { "module": "commonjs", "target": "es5", diff --git a/modules/@angular/compiler/test/offline_compiler_util.ts b/modules/@angular/compiler/test/offline_compiler_util.ts index 5336ccb3f6..f7aec83358 100644 --- a/modules/@angular/compiler/test/offline_compiler_util.ts +++ b/modules/@angular/compiler/test/offline_compiler_util.ts @@ -71,4 +71,4 @@ export class SimpleJsImportGenerator implements ImportGenerator { return importedUrlStr; } } -} \ No newline at end of file +} diff --git a/modules/@angular/compiler/tsconfig-es2015.json b/modules/@angular/compiler/tsconfig-es2015.json index 04d3b21b88..c37d439b74 100644 --- a/modules/@angular/compiler/tsconfig-es2015.json +++ b/modules/@angular/compiler/tsconfig-es2015.json @@ -1,7 +1,4 @@ { - "angularCompilerOptions": { - "skipTemplateCodegen": true - }, "compilerOptions": { "baseUrl": ".", "declaration": true, diff --git a/modules/@angular/compiler/tsconfig-es5.json b/modules/@angular/compiler/tsconfig-es5.json index b71e05fd7e..2a9f278580 100644 --- a/modules/@angular/compiler/tsconfig-es5.json +++ b/modules/@angular/compiler/tsconfig-es5.json @@ -1,12 +1,8 @@ { - "angularCompilerOptions": { - "skipTemplateCodegen": true - }, "compilerOptions": { "baseUrl": ".", "declaration": true, "stripInternal": true, - "emitDecoratorMetadata": true, "experimentalDecorators": true, "module": "commonjs", "moduleResolution": "node", diff --git a/modules/@angular/core/src/di/decorators.ts b/modules/@angular/core/src/di/decorators.ts index 61db34eb65..ec7cb70b1f 100644 --- a/modules/@angular/core/src/di/decorators.ts +++ b/modules/@angular/core/src/di/decorators.ts @@ -60,18 +60,21 @@ export interface SkipSelfMetadataFactory { /** * Factory for creating {@link InjectMetadata}. * @stable + * @Annotation */ export var Inject: InjectMetadataFactory = makeParamDecorator(InjectMetadata); /** * Factory for creating {@link OptionalMetadata}. * @stable + * @Annotation */ export var Optional: OptionalMetadataFactory = makeParamDecorator(OptionalMetadata); /** * Factory for creating {@link InjectableMetadata}. * @stable + * @Annotation */ export var Injectable: InjectableMetadataFactory = makeDecorator(InjectableMetadata); @@ -79,17 +82,20 @@ export var Injectable: InjectableMetadataFactory = /** * Factory for creating {@link SelfMetadata}. * @stable + * @Annotation */ export var Self: SelfMetadataFactory = makeParamDecorator(SelfMetadata); /** * Factory for creating {@link HostMetadata}. * @stable + * @Annotation */ export var Host: HostMetadataFactory = makeParamDecorator(HostMetadata); /** * Factory for creating {@link SkipSelfMetadata}. * @stable + * @Annotation */ export var SkipSelf: SkipSelfMetadataFactory = makeParamDecorator(SkipSelfMetadata); diff --git a/modules/@angular/core/src/metadata.ts b/modules/@angular/core/src/metadata.ts index 7aed836661..acf360979d 100644 --- a/modules/@angular/core/src/metadata.ts +++ b/modules/@angular/core/src/metadata.ts @@ -471,6 +471,7 @@ export interface HostListenerMetadataFactory { * * {@example core/ts/metadata/metadata.ts region='component'} * @stable + * @Annotation */ export var Component: ComponentMetadataFactory = makeDecorator(ComponentMetadata, (fn: any) => fn.View = View); @@ -854,6 +855,7 @@ export var Component: ComponentMetadataFactory = * the instantiated * view occurs on the second `
  • ` which is a sibling to the `