2
2
@name Conceptual Overview
3
3
@description
4
4
5
- There are some concepts within Angular that you should understand before creating your first application.
6
- This section touches all important parts of Angular really quickly using a simple example.
7
- However, it won't explain all details .
8
- For a more in-depth explanation, have a look at the {@link tutorial/ tutorial}.
5
+ # Conceptual Overview
6
+
7
+ This section briefly touches on all of the important parts of AngularJS using a simple example .
8
+ For a more in-depth explanation, see the {@link tutorial/ tutorial}.
9
9
10
10
| Concept | Description |
11
11
|------------------|------------------------------------------|
@@ -25,7 +25,7 @@ For a more in-depth explanation, have a look at the {@link tutorial/ tutorial}.
25
25
|{@link concepts#service Service} | reusable business logic independent of views |
26
26
27
27
28
- # A first example: Data binding
28
+ ## A first example: Data binding
29
29
30
30
In the following example we will build a form to calculate the costs of an invoice in different currencies.
31
31
@@ -97,7 +97,7 @@ recalculated and the DOM is updated with their values.
97
97
The concept behind this is <a name="databinding">"{@link databinding two-way data binding}"</a>.
98
98
99
99
100
- # Adding UI logic: Controllers
100
+ ## Adding UI logic: Controllers
101
101
102
102
Let's add some more logic to the example that allows us to enter and calculate the costs in
103
103
different currencies and also pay the invoice.
@@ -181,7 +181,7 @@ The following graphic shows how everything works together after we introduced th
181
181
182
182
<img style="padding-left: 3em; padding-bottom: 1em;" src="img/guide/concepts-databinding2.png">
183
183
184
- # View independent business logic: Services
184
+ ## View independent business logic: Services
185
185
186
186
Right now, the `InvoiceController` contains all logic of our example. When the application grows it
187
187
is a good practice to move view independent logic from the controller into a so called
@@ -297,7 +297,7 @@ Angular uses this array syntax to define the dependencies so that the DI also wo
297
297
the code, which will most probably rename the argument name of the controller constructor function
298
298
to something shorter like `a`.
299
299
300
- # Accessing the backend
300
+ ## Accessing the backend
301
301
302
302
Let's finish our example by fetching the exchange rates from the Yahoo Finance API.
303
303
The following example shows how this is done with Angular:
@@ -379,8 +379,8 @@ The following example shows how this is done with Angular:
379
379
</example>
380
380
381
381
What changed?
382
- Our `currencyConverter` service of the `finance` module now uses the
383
- {@link ng.$http $http} service, a builtin service provided by Angular
384
- for accessing the backend. It is a wrapper around [`XMLHttpRequest`](https://developer.mozilla.org/en-US/docs/Web/API/XMLHttpRequest)
385
- and [JSONP](http://en.wikipedia.org/wiki/JSONP) transports. Details can be found in the api docs of that service.
382
+ Our `currencyConverter` service of the `finance` module now uses the {@link ng.$http `$http`}, a
383
+ built-in service provided by Angular for accessing a server backend. `$http` is a wrapper around
384
+ [`XMLHttpRequest`](https://developer.mozilla.org/en-US/docs/Web/API/XMLHttpRequest)
385
+ and [JSONP](http://en.wikipedia.org/wiki/JSONP) transports.
386
386
0 commit comments