aboutsummaryrefslogtreecommitdiffstats
path: root/docs
diff options
context:
space:
mode:
authorBrian Ford2013-10-11 16:07:43 -0700
committerBrian Ford2013-10-11 16:15:36 -0700
commitc40b977d94c9364387c9feae7846ff3b885e1534 (patch)
treedb34088a4fbb0cde4a88af037abd08ec2519133f /docs
parent8ec7668131b4de727400088bf2603457d57eb581 (diff)
downloadangular.js-c40b977d94c9364387c9feae7846ff3b885e1534.tar.bz2
docs(tutorial/step11): use DI annotations, fix summary
Diffstat (limited to 'docs')
-rw-r--r--docs/content/tutorial/step_11.ngdoc18
1 files changed, 10 insertions, 8 deletions
diff --git a/docs/content/tutorial/step_11.ngdoc b/docs/content/tutorial/step_11.ngdoc
index fcc0ffe0..6ab7a781 100644
--- a/docs/content/tutorial/step_11.ngdoc
+++ b/docs/content/tutorial/step_11.ngdoc
@@ -39,12 +39,14 @@ __`app/index.html`.__
__`app/js/services.js`.__
<pre>
-var phonecatApp = angular.module('phonecatServices', ['ngResource']).
- factory('Phone', function($resource){
- return $resource('phones/:phoneId.json', {}, {
- query: {method:'GET', params:{phoneId:'phones'}, isArray:true}
- });
-});
+var phonecatServices = angular.module('phonecatServices', ['ngResource']);
+
+phonecatServices.factory('Phone', ['$resource',
+ function($resource){
+ return $resource('phones/:phoneId.json', {}, {
+ query: {method:'GET', params:{phoneId:'phones'}, isArray:true}
+ });
+ }]);
</pre>
We used the module API to register a custom service using a factory function. We passed in the name
@@ -215,8 +217,8 @@ You should now see the following output in the Karma tab:
# Summary
-There you have it! We have created a web app in a relatively short amount of time. In the {@link
-the_end closing notes} we'll cover where to go from here.
+With the phone image swapper in place, we're ready for {@link step_12 step 12} (the last step!) to
+learn how to improve this application with animations.
<ul doc-tutorial-nav="11"></ul>