Skip to content
This repository was archived by the owner on Dec 4, 2017. It is now read-only.

Commit 9cf71d4

Browse files
authored
docs(http/toh-6): improve references to in-mem-web-api (#2964)
1 parent 20f47aa commit 9cf71d4

File tree

2 files changed

+14
-11
lines changed

2 files changed

+14
-11
lines changed

public/docs/ts/latest/guide/server-communication.jade

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@ block includes
3232
<li> [Search parameters](#search-parameters).</li>
3333
<li> [More fun with observables](#more-observables).</li>
3434
</ul>
35-
- [Guarding against Cross-Site Request Forgery](#xsrf)
36-
- [Appendix: Tour of Heroes in-memory server](#in-mem-web-api).
35+
- [Guarding against Cross-Site Request Forgery](#xsrf).
36+
- [Appendix: Tour of Heroes _in-memory web api_](#in-mem-web-api).
3737

3838
A <live-example>live example</live-example> illustrates these topics.
3939

@@ -669,14 +669,18 @@ a#in-mem-web-api
669669
The *get heroes* scenario would work,
670670
but since the app can't save changes to a JSON file, it needs a web API server.
671671
Because there isn't a real server for this demo,
672-
it uses an *in-memory web API simulator* instead.
672+
it substitutes the Angular _in-memory web api_ simulator for the actual XHR backend service.
673673

674674
.l-sub-section
675675
:marked
676-
The in-memory web api is not part of the Angular core.
677-
It's an optional service in its own `angular-in-memory-web-api` library
678-
installed with npm (see `package.json`) and
679-
registered for module loading by SystemJS (see `systemjs.config.js`).
676+
The in-memory web api is not part of Angular _proper_.
677+
It's an optional service in its own
678+
<a href="https://github.com/angular/in-memory-web-api" target="_blank" title="In-memory Web API"><i>angular-in-memory-web-api</i></a>
679+
library installed with npm (see `package.json`).
680+
681+
See the
682+
<a href="https://github.com/angular/in-memory-web-api/blob/master/README.md" target="_blank" title='In-memory Web API "README.md"'><i>README file</i></a>
683+
for configuration options, default behaviors, and limitations.
680684

681685
:marked
682686
The in-memory web API gets its data from !{_a_ca_class_with} a `createDb()`

public/docs/ts/latest/tutorial/toh-pt6.jade

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -91,10 +91,9 @@ block http-providers
9191

9292
block backend
9393
:marked
94-
We're importing the `InMemoryWebApiModule` and adding it to the module `imports`.
95-
The `InMemoryWebApiModule` replaces the default `Http` client backend &mdash;
96-
the supporting service that talks to the remote server &mdash;
97-
with an _in-memory web API alternative service_.
94+
Rather than require a real API server, this example simulates communication with the remote server by adding the
95+
<a href="https://github.com/angular/in-memory-web-api" target="_blank" title="In-memory Web API"><i>InMemoryWebApiModule</i></a>
96+
to the module `imports`, effectively replacing the `Http` client's XHR backend service with an in-memory alternative.
9897

9998
+makeExcerpt(_appModuleTsVsMainTs, 'in-mem-web-api', '')
10099

0 commit comments

Comments
 (0)