@@ -456,6 +456,12 @@ figure.image-display
456
456
457
457
+ makeExample('upgrade-module/ts/app/1-2-hybrid-bootstrap/app.module.ts' , 'bootstrap' )
458
458
459
+ :marked
460
+ We also need to install the `@angular/upgrade` package via `npm install @angular/upgrade --save`
461
+ and add a mapping for the `@angular/upgrade/static` package:
462
+
463
+ + makeExample('upgrade-module/ts/systemjs.config.1.js' , 'upgrade-static-umd' , 'systemjs.config.js (map)' )
464
+
459
465
:marked
460
466
Congratulations! You're running a hybrid Angular 1+2 application! The
461
467
existing Angular 1 code works as before _and_ you're ready to run Angular 2 code.
@@ -1122,8 +1128,12 @@ code-example(format="").
1122
1128
1123
1129
:marked
1124
1130
In the `systemjs.config.js` file we got from the Quickstart we also need to make a couple
1125
- of adjustments because of our project structure. We want to point the browser to the project
1126
- root when loading things through SystemJS, instead of using the `<base>` URL:
1131
+ of adjustments because of our project structure.
1132
+ We want to point the browser to the project root when loading things through SystemJS,
1133
+ instead of using the `<base>` URL.
1134
+
1135
+ We also need to install the `upgrade` package via `npm install @angular/upgrade --save`
1136
+ and add a mapping for the `@angular/upgrade/static` package.
1127
1137
1128
1138
+ makeExample('upgrade-phonecat-2-hybrid/ts/systemjs.config.1.js' , 'paths' , 'systemjs.config.js' )
1129
1139
@@ -1601,11 +1611,15 @@ code-example(format="").
1601
1611
* `app/core/phone/phone.module.ts`
1602
1612
* `app/phone-detail/phone-detail.module.ts`
1603
1613
* `app/phone-list/phone-list.module.ts`
1604
-
1614
+
1605
1615
The external typings for Angular 1 may be uninstalled as well. The only ones
1606
1616
we still need are for Jasmine and Angular 2 polyfills.
1607
1617
1618
+ The `@angular/upgrade` package and it's mapping in `systemjs.config.js` can also go,
1619
+ we don't need them anymore.
1620
+
1608
1621
code-example( format ="" ) .
1622
+ npm uninstall @angular/upgrade --save
1609
1623
npm uninstall @types/angular @types/angular-animate @types/angular-cookies @types/angular-mocks @types/angular-resource @types/angular-route @types/angular-sanitize --save-dev
1610
1624
1611
1625
:marked
0 commit comments