From c659c333ae08c6c3e7a56d1b7882c96aa8bed27d Mon Sep 17 00:00:00 2001 From: matthewhegarty Date: Mon, 19 Sep 2016 13:01:30 +0100 Subject: [PATCH 1/5] Fixed typo which was referring to 'imports' section and not 'setup' section --- public/docs/ts/latest/guide/testing.jade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/docs/ts/latest/guide/testing.jade b/public/docs/ts/latest/guide/testing.jade index 3e61e0023a..b6d63193c5 100644 --- a/public/docs/ts/latest/guide/testing.jade +++ b/public/docs/ts/latest/guide/testing.jade @@ -438,7 +438,7 @@ a#simple-component-test +makeExample('testing/ts/app/banner.component.spec.ts', 'imports', 'app/banner.component.spec.ts (imports)')(format='.') :marked Here's the setup for the tests followed by observations about the `beforeEach`: -+makeExample('testing/ts/app/banner.component.spec.ts', 'setup', 'app/banner.component.spec.ts (imports)')(format='.') ++makeExample('testing/ts/app/banner.component.spec.ts', 'setup', 'app/banner.component.spec.ts (setup)')(format='.') :marked `TestBed.configureTestingModule` takes an `@NgModule`-like metadata object. This one simply declares the component to test, `BannerComponent`. From 33d21aafe41c2e726c35d8b766a80d283d1c61ea Mon Sep 17 00:00:00 2001 From: matthewhegarty Date: Sat, 1 Oct 2016 10:42:03 +0100 Subject: [PATCH 2/5] Fixed 1 char typo: /he *Cancel/the *Cancel/ --- public/docs/ts/latest/guide/router.jade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/docs/ts/latest/guide/router.jade b/public/docs/ts/latest/guide/router.jade index a35b29bde1..6508fd41e6 100644 --- a/public/docs/ts/latest/guide/router.jade +++ b/public/docs/ts/latest/guide/router.jade @@ -1795,7 +1795,7 @@ h3#can-deactivate-guard CanDeactivate: handling unsaved changes Users update crisis information in the `CrisisDetailComponent`. Unlike the `HeroDetailComponent`, the user changes do not update the crisis entity immediately. We update the entity when the user presses the *Save* button. - We discard the changes if the user presses he *Cancel* button. + We discard the changes if the user presses the *Cancel* button. Both buttons navigate back to the crisis list after save or cancel. From 23eee50cf8f2cc35c8cf303a8c1c1204b58d2683 Mon Sep 17 00:00:00 2001 From: matthewhegarty Date: Sat, 1 Oct 2016 11:16:37 +0100 Subject: [PATCH 3/5] Fixed broken link: router.html#optional-route-parameter (added an 's' to 'parameter') --- public/docs/ts/latest/guide/router.jade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/docs/ts/latest/guide/router.jade b/public/docs/ts/latest/guide/router.jade index 6508fd41e6..5955879b5f 100644 --- a/public/docs/ts/latest/guide/router.jade +++ b/public/docs/ts/latest/guide/router.jade @@ -728,7 +728,7 @@ code-example(format="." language="bash"). the value `15` in the path clearly distinguishes the route to "Magneta" from a route for some other hero. - An [optional-route-parameter](#optional-route-parameter) might be a better choice if we were passing an *optional* value to `HeroDetailComponent`. + An [optional-route-parameter](#optional-route-parameters) might be a better choice if we were passing an *optional* value to `HeroDetailComponent`. a#navigate :marked From ea7d99960fc8ef5846c41ea9cef99e81afe70317 Mon Sep 17 00:00:00 2001 From: matthewhegarty Date: Sat, 1 Oct 2016 11:53:24 +0100 Subject: [PATCH 4/5] corrected grammar: /affords/afford/ --- public/docs/ts/latest/guide/router.jade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/docs/ts/latest/guide/router.jade b/public/docs/ts/latest/guide/router.jade index 5955879b5f..95a73bf042 100644 --- a/public/docs/ts/latest/guide/router.jade +++ b/public/docs/ts/latest/guide/router.jade @@ -935,7 +935,7 @@ figure.image-display doing so greatly complicates the pattern matching required to translate an incoming URL to a named route. Optional parameters are the ideal vehicle for conveying arbitrarily complex information during navigation. - Optional parameters aren't involved in pattern matching and affords enormous flexibility of expression. + Optional parameters aren't involved in pattern matching and afford enormous flexibility of expression. The Router supports navigation with optional parameters as well as required route parameters. We define _optional_ parameters in an *object* after we define our required route parameters. From e33abe3ee2bcf080cda4f3da1d8c6f09340a7a22 Mon Sep 17 00:00:00 2001 From: matthewhegarty Date: Sat, 1 Oct 2016 14:59:04 +0100 Subject: [PATCH 5/5] Fixed typo: /moved them/move them/ --- public/docs/ts/latest/guide/router.jade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/docs/ts/latest/guide/router.jade b/public/docs/ts/latest/guide/router.jade index a35b29bde1..9c229dc341 100644 --- a/public/docs/ts/latest/guide/router.jade +++ b/public/docs/ts/latest/guide/router.jade @@ -1900,7 +1900,7 @@ h3#resolve-guard Resolve: pre-fetching component data +makeExample('app/crisis-center/crisis-detail-resolve.service.ts', '') :marked - We'll take the relevant parts of the `ngOnInit` lifecycle hook in our `CrisisDetailComponent` and moved them into our `CrisisDetailResolve` guard. + We'll take the relevant parts of the `ngOnInit` lifecycle hook in our `CrisisDetailComponent` and move them into our `CrisisDetailResolve` guard. We import the `Crisis` model and `CrisisService` and also the `Router` for navigation from our resolve implementation. We want to be explicit about the data we are resolving, so we implement the `Resolve` interface with a type of `Crisis`. This lets us know that what we will resolve will match our `Crisis` model. We inject the `CrisisService` and `Router` and implement the `resolve` method that supports a `Promise`, `Observable` or a synchronous