diff --git a/aio/content/examples/.gitignore b/aio/content/examples/.gitignore index 761853450c..d40a958d04 100644 --- a/aio/content/examples/.gitignore +++ b/aio/content/examples/.gitignore @@ -60,6 +60,8 @@ dist/ !rollup-config.js aot-compiler/**/*.d.ts aot-compiler/**/*.factory.d.ts +upgrade-phonecat-2-hybrid/aot/**/* +!upgrade-phonecat-2-hybrid/aot/index.html # i18n !i18n/src/systemjs-text-plugin.js diff --git a/aio/content/examples/upgrade-phonecat-1-typescript/tsconfig.ajs.json b/aio/content/examples/upgrade-phonecat-1-typescript/tsconfig.ajs.json index 53da36ca95..8a60b91b02 100644 --- a/aio/content/examples/upgrade-phonecat-1-typescript/tsconfig.ajs.json +++ b/aio/content/examples/upgrade-phonecat-1-typescript/tsconfig.ajs.json @@ -8,6 +8,7 @@ "experimentalDecorators": true, "removeComments": false, "noImplicitAny": false, + "skipLibCheck": true, "suppressImplicitAnyIndexErrors": true } } diff --git a/aio/content/examples/upgrade-phonecat-1-typescript/tsconfig.json b/aio/content/examples/upgrade-phonecat-1-typescript/tsconfig.json index 8444d2ddea..1d3d14ae78 100644 --- a/aio/content/examples/upgrade-phonecat-1-typescript/tsconfig.json +++ b/aio/content/examples/upgrade-phonecat-1-typescript/tsconfig.json @@ -8,10 +8,8 @@ "experimentalDecorators": true, "lib": [ "es2015", "dom" ], "noImplicitAny": true, - "suppressImplicitAnyIndexErrors": true, - "typeRoots": [ - "./node_modules/@types/" - ] + "skipLibCheck": true, + "suppressImplicitAnyIndexErrors": true }, "compileOnSave": true, "exclude": [ diff --git a/aio/content/examples/upgrade-phonecat-2-hybrid/app/main-aot.ts b/aio/content/examples/upgrade-phonecat-2-hybrid/app/main-aot.ts index bbf091409d..d81fae073b 100644 --- a/aio/content/examples/upgrade-phonecat-2-hybrid/app/main-aot.ts +++ b/aio/content/examples/upgrade-phonecat-2-hybrid/app/main-aot.ts @@ -1,6 +1,6 @@ // #docregion import { platformBrowser } from '@angular/platform-browser'; -import { AppModuleNgFactory } from '../aot/app/app.module.ngfactory'; +import { AppModuleNgFactory } from './app.module.ngfactory'; platformBrowser().bootstrapModuleFactory(AppModuleNgFactory); diff --git a/aio/content/examples/upgrade-phonecat-2-hybrid/app/phone-detail/phone-detail.component.spec.ts b/aio/content/examples/upgrade-phonecat-2-hybrid/app/phone-detail/phone-detail.component.spec.ts index 260794b98b..49a3bbf1cd 100644 --- a/aio/content/examples/upgrade-phonecat-2-hybrid/app/phone-detail/phone-detail.component.spec.ts +++ b/aio/content/examples/upgrade-phonecat-2-hybrid/app/phone-detail/phone-detail.component.spec.ts @@ -3,7 +3,7 @@ import { ActivatedRoute } from '@angular/router'; // #enddocregion activatedroute -import { Observable } from 'rxjs'; +import { Observable, of } from 'rxjs'; import { async, TestBed } from '@angular/core/testing'; @@ -21,7 +21,7 @@ function xyzPhoneData(): PhoneData { class MockPhone { get(id: string): Observable { - return Observable.of(xyzPhoneData()); + return of(xyzPhoneData()); } } diff --git a/aio/content/examples/upgrade-phonecat-2-hybrid/app/phone-list/phone-list.component.spec.ts b/aio/content/examples/upgrade-phonecat-2-hybrid/app/phone-list/phone-list.component.spec.ts index db77d7c844..21bd8182b7 100644 --- a/aio/content/examples/upgrade-phonecat-2-hybrid/app/phone-list/phone-list.component.spec.ts +++ b/aio/content/examples/upgrade-phonecat-2-hybrid/app/phone-list/phone-list.component.spec.ts @@ -2,7 +2,7 @@ // #docregion import { NO_ERRORS_SCHEMA } from '@angular/core'; import { ActivatedRoute } from '@angular/router'; -import { Observable } from 'rxjs'; +import { Observable, of } from 'rxjs'; import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { SpyLocation } from '@angular/common/testing'; @@ -15,7 +15,7 @@ class ActivatedRouteMock { class MockPhone { query(): Observable { - return Observable.of([ + return of([ {name: 'Nexus S', snippet: '', images: []}, {name: 'Motorola DROID', snippet: '', images: []} ]); diff --git a/aio/content/examples/upgrade-phonecat-2-hybrid/tsconfig-aot.json b/aio/content/examples/upgrade-phonecat-2-hybrid/tsconfig-aot.json index 91807a25a9..c7f1231897 100644 --- a/aio/content/examples/upgrade-phonecat-2-hybrid/tsconfig-aot.json +++ b/aio/content/examples/upgrade-phonecat-2-hybrid/tsconfig-aot.json @@ -9,10 +9,8 @@ "lib": ["es2015", "dom"], "removeComments": false, "noImplicitAny": true, - "suppressImplicitAnyIndexErrors": true, - "typeRoots": [ - "./node_modules/@types/" - ] + "skipLibCheck": true, + "suppressImplicitAnyIndexErrors": true }, "files": [ @@ -21,7 +19,6 @@ ], "angularCompilerOptions": { - "genDir": "aot", - "skipMetadataEmit" : true + "skipMetadataEmit" : true } } diff --git a/aio/content/examples/upgrade-phonecat-2-hybrid/tsconfig.json b/aio/content/examples/upgrade-phonecat-2-hybrid/tsconfig.json index bdf16643ce..5ee3c82f1e 100644 --- a/aio/content/examples/upgrade-phonecat-2-hybrid/tsconfig.json +++ b/aio/content/examples/upgrade-phonecat-2-hybrid/tsconfig.json @@ -8,10 +8,8 @@ "experimentalDecorators": true, "lib": [ "es2015", "dom" ], "noImplicitAny": true, - "suppressImplicitAnyIndexErrors": true, - "typeRoots": [ - "./node_modules/@types/" - ] + "skipLibCheck": true, + "suppressImplicitAnyIndexErrors": true }, "compileOnSave": true, "exclude": [ diff --git a/aio/content/examples/upgrade-phonecat-3-final/app/phone-detail/phone-detail.component.spec.ts b/aio/content/examples/upgrade-phonecat-3-final/app/phone-detail/phone-detail.component.spec.ts index 260794b98b..49a3bbf1cd 100644 --- a/aio/content/examples/upgrade-phonecat-3-final/app/phone-detail/phone-detail.component.spec.ts +++ b/aio/content/examples/upgrade-phonecat-3-final/app/phone-detail/phone-detail.component.spec.ts @@ -3,7 +3,7 @@ import { ActivatedRoute } from '@angular/router'; // #enddocregion activatedroute -import { Observable } from 'rxjs'; +import { Observable, of } from 'rxjs'; import { async, TestBed } from '@angular/core/testing'; @@ -21,7 +21,7 @@ function xyzPhoneData(): PhoneData { class MockPhone { get(id: string): Observable { - return Observable.of(xyzPhoneData()); + return of(xyzPhoneData()); } } diff --git a/aio/content/examples/upgrade-phonecat-3-final/app/phone-list/phone-list.component.spec.ts b/aio/content/examples/upgrade-phonecat-3-final/app/phone-list/phone-list.component.spec.ts index 244c898461..588eabe76e 100644 --- a/aio/content/examples/upgrade-phonecat-3-final/app/phone-list/phone-list.component.spec.ts +++ b/aio/content/examples/upgrade-phonecat-3-final/app/phone-list/phone-list.component.spec.ts @@ -2,7 +2,7 @@ // #docregion routestuff import { NO_ERRORS_SCHEMA } from '@angular/core'; import { ActivatedRoute } from '@angular/router'; -import { Observable } from 'rxjs'; +import { Observable, of } from 'rxjs'; import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { SpyLocation } from '@angular/common/testing'; @@ -17,7 +17,7 @@ class ActivatedRouteMock { class MockPhone { query(): Observable { - return Observable.of([ + return of([ {name: 'Nexus S', snippet: '', images: []}, {name: 'Motorola DROID', snippet: '', images: []} ]); diff --git a/aio/content/examples/upgrade-phonecat-3-final/tsconfig.json b/aio/content/examples/upgrade-phonecat-3-final/tsconfig.json index bdf16643ce..5ee3c82f1e 100644 --- a/aio/content/examples/upgrade-phonecat-3-final/tsconfig.json +++ b/aio/content/examples/upgrade-phonecat-3-final/tsconfig.json @@ -8,10 +8,8 @@ "experimentalDecorators": true, "lib": [ "es2015", "dom" ], "noImplicitAny": true, - "suppressImplicitAnyIndexErrors": true, - "typeRoots": [ - "./node_modules/@types/" - ] + "skipLibCheck": true, + "suppressImplicitAnyIndexErrors": true }, "compileOnSave": true, "exclude": [ diff --git a/aio/package.json b/aio/package.json index 6fde4027d0..b8cdcaff5f 100644 --- a/aio/package.json +++ b/aio/package.json @@ -32,7 +32,7 @@ "test-pwa-score": "node scripts/test-pwa-score", "example-e2e": "yarn example-check-local && node ./tools/examples/run-example-e2e", "example-lint": "tslint -c \"content/examples/tslint.json\" \"content/examples/**/*.ts\" -e \"content/examples/styleguide/**/*.avoid.ts\"", - "example-use-local": "node tools/ng-packages-installer overwrite ./tools/examples/shared", + "example-use-local": "node tools/ng-packages-installer overwrite ./tools/examples/shared --debug", "example-use-npm": "node tools/ng-packages-installer restore ./tools/examples/shared", "example-check-local": "node tools/ng-packages-installer check ./tools/examples/shared", "deploy-preview": "scripts/deploy-preview.sh", diff --git a/aio/tools/examples/run-example-e2e.js b/aio/tools/examples/run-example-e2e.js index e7d6291d0b..dba71961c4 100644 --- a/aio/tools/examples/run-example-e2e.js +++ b/aio/tools/examples/run-example-e2e.js @@ -18,7 +18,6 @@ const EXAMPLE_CONFIG_FILENAME = 'example-config.json'; const IGNORED_EXAMPLES = [ // temporary ignores 'quickstart', 'setup', - 'upgrade-p' ]; /** diff --git a/aio/tools/examples/shared/boilerplate/systemjs/src/tsconfig.json b/aio/tools/examples/shared/boilerplate/systemjs/src/tsconfig.json index eefc5bb779..e12e9a7fec 100644 --- a/aio/tools/examples/shared/boilerplate/systemjs/src/tsconfig.json +++ b/aio/tools/examples/shared/boilerplate/systemjs/src/tsconfig.json @@ -8,10 +8,8 @@ "experimentalDecorators": true, "lib": [ "es2015", "dom" ], "noImplicitAny": true, - "suppressImplicitAnyIndexErrors": true, - "typeRoots": [ - "../node_modules/@types/" - ] + "skipLibCheck": true, + "suppressImplicitAnyIndexErrors": true }, "compileOnSave": true, "exclude": [ diff --git a/aio/tools/examples/shared/package.json b/aio/tools/examples/shared/package.json index 0e3ff282e5..1267ad5a67 100644 --- a/aio/tools/examples/shared/package.json +++ b/aio/tools/examples/shared/package.json @@ -45,16 +45,15 @@ "@angular/compiler-cli": "^6.0.0", "@angular/language-service": "^6.0.0", "@angular/platform-server": "^6.0.0", - "@types/angular": "^1.5.16", - "@types/angular-animate": "^1.5.5", - "@types/angular-cookies": "^1.4.2", - "@types/angular-mocks": "^1.5.5", - "@types/angular-resource": "^1.5.6", - "@types/angular-route": "^1.3.2", - "@types/angular-sanitize": "^1.3.3", + "@types/angular": "^1.6.47", + "@types/angular-animate": "^1.5.10", + "@types/angular-mocks": "^1.6.0", + "@types/angular-resource": "^1.5.14", + "@types/angular-route": "^1.3.5", "@types/express": "^4.0.35", "@types/jasmine": "~2.8.0", "@types/jasminewd2": "^2.0.3", + "@types/jquery": "^3.3.4", "@types/node": "^6.0.45", "canonical-path": "0.0.2", "concurrently": "^3.0.0", diff --git a/aio/tools/examples/shared/yarn.lock b/aio/tools/examples/shared/yarn.lock index ab9ed54dc6..18af4cf4ea 100644 --- a/aio/tools/examples/shared/yarn.lock +++ b/aio/tools/examples/shared/yarn.lock @@ -240,45 +240,33 @@ version "0.7.0" resolved "https://registry.yarnpkg.com/@sindresorhus/is/-/is-0.7.0.tgz#9a06f4f137ee84d7df0460c1fdb1135ffa6c50fd" -"@types/angular-animate@^1.5.5": - version "1.5.8" - resolved "https://registry.yarnpkg.com/@types/angular-animate/-/angular-animate-1.5.8.tgz#578e058ee0ca5539e1795421a91ae2f52581dc8f" +"@types/angular-animate@^1.5.10": + version "1.5.10" + resolved "https://registry.yarnpkg.com/@types/angular-animate/-/angular-animate-1.5.10.tgz#b94b45358c61163f1478768e8b081c76439c515f" dependencies: "@types/angular" "*" -"@types/angular-cookies@^1.4.2": - version "1.4.5" - resolved "https://registry.yarnpkg.com/@types/angular-cookies/-/angular-cookies-1.4.5.tgz#f5ccf5f42a7b9f4d13e77afb8722034ea9f40bd3" +"@types/angular-mocks@^1.6.0": + version "1.6.0" + resolved "https://registry.yarnpkg.com/@types/angular-mocks/-/angular-mocks-1.6.0.tgz#bd32f55b678c239880d2d0d9a3a79b5cad45547e" dependencies: "@types/angular" "*" -"@types/angular-mocks@^1.5.5": - version "1.5.11" - resolved "https://registry.yarnpkg.com/@types/angular-mocks/-/angular-mocks-1.5.11.tgz#d5bbefbf742f2196071bda0fe051878b6f4fd72c" - dependencies: - "@types/angular" "*" - -"@types/angular-resource@^1.5.6": +"@types/angular-resource@^1.5.14": version "1.5.14" resolved "https://registry.yarnpkg.com/@types/angular-resource/-/angular-resource-1.5.14.tgz#902f34e8c98f708ae99493c6d416b39b4a22d9fe" dependencies: "@types/angular" "*" -"@types/angular-route@^1.3.2": - version "1.3.4" - resolved "https://registry.yarnpkg.com/@types/angular-route/-/angular-route-1.3.4.tgz#10d3f7eb313fb8a4b832041f9401869803dcd4df" +"@types/angular-route@^1.3.5": + version "1.3.5" + resolved "https://registry.yarnpkg.com/@types/angular-route/-/angular-route-1.3.5.tgz#78b8e0b069d5efe55ec7072461f4e2f6ae20767b" dependencies: "@types/angular" "*" -"@types/angular-sanitize@^1.3.3": - version "1.3.6" - resolved "https://registry.yarnpkg.com/@types/angular-sanitize/-/angular-sanitize-1.3.6.tgz#fec2bd040d38708e46f02e66fba5199e8a64b22e" - dependencies: - "@types/angular" "*" - -"@types/angular@*", "@types/angular@^1.5.16": - version "1.6.36" - resolved "https://registry.yarnpkg.com/@types/angular/-/angular-1.6.36.tgz#15e73d632274b5655a391470844863548c7755f4" +"@types/angular@*", "@types/angular@^1.6.47": + version "1.6.47" + resolved "https://registry.yarnpkg.com/@types/angular/-/angular-1.6.47.tgz#f7a31279a02c0892ed9aa76aae2da1b17791bacd" "@types/body-parser@*": version "1.16.7" @@ -315,6 +303,10 @@ dependencies: "@types/jasmine" "*" +"@types/jquery@^3.3.4": + version "3.3.4" + resolved "https://registry.yarnpkg.com/@types/jquery/-/jquery-3.3.4.tgz#f1850fb9a70041a14ace4f81a7ed782db8548317" + "@types/mime@*": version "2.0.0" resolved "https://registry.yarnpkg.com/@types/mime/-/mime-2.0.0.tgz#5a7306e367c539b9f6543499de8dd519fac37a8b"