You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 12, 2024. It is now read-only.
' <li><p>Reset the workspace to step '+step+'.</p>'+
39
-
' <pre>'+command+'</pre></li>\n'+
40
-
' <li><p>Refresh your browser or check the app out on <a href="http://angular.github.com/angular-phonecat/step-'+step+'/app">Angular\'s server</a>.</p></li>\n'+
' <li><p>Refresh your browser or check the app out on <a href="http://angular.github.com/angular-phonecat/step-{{step}}/app">Angular\'s server</a>.</p></li>\n'+
<li>Configure the server to serve the files in the <code>angular-phonecat</code> directory.</li>
36
-
<li>Navigate in your browser to <code>http://localhost:[port-number]/[context-path]/app/index.html</code>.</li>
37
-
</ol>
38
-
</li>
39
-
</ul>
40
-
</li>
41
-
</ol>
42
-
</div>
43
-
44
-
45
-
<div class="tab-pane well" id="git-win" title="Git on Windows" value="gitWin">
46
-
<ol>
47
-
<li><p>Open Git bash and run this command (in <code>angular-phonecat</code> directory):</p>
48
-
<pre>git checkout -f step-0</pre>
49
-
<p>This resets your workspace to step 0 of the tutorial app.</p>
50
-
<p>You must repeat this for every future step in the tutorial and change the number to
51
-
the number of the step you are on. This will cause any changes you made within
52
-
your working directory to be lost.</p></li>
53
-
<li>To see the app running in a browser, do one of the following:
54
-
<ul>
55
-
<li><b>For node.js users:</b>
56
-
<ol>
57
-
<li>In a <i>separate</i> terminal tab or window, run <code>node scripts\web-server.js</code> to start the web server.</li>
58
-
<li>Open a browser window for the app and navigate to <a href="http://localhost:8000/app/index.html" target="_blank">`http://localhost:8000/app/index.html`</a></li>
59
-
</ol>
60
-
</li>
61
-
<li><b>For other http servers:</b>
62
-
<ol>
63
-
<li>Configure the server to serve the files in the <code>angular-phonecat</code> directory.</li>
64
-
<li>Navigate in your browser to <code>http://localhost:[port-number]/[context-path]/app/index.html</code>.</li>
65
-
</ol>
66
-
</li>
67
-
</ul>
68
-
</li>
69
-
</ol>
70
-
</div>
71
-
</div>
14
+
In `angular-phonecat` directory, run this command:
72
15
16
+
```
17
+
git checkout -f step-0
18
+
```
19
+
20
+
21
+
This resets your workspace to step 0 of the tutorial app.
22
+
23
+
You must repeat this for every future step in the tutorial and change the number to the number of
24
+
the step you are on. This will cause any changes you made within your working directory to be lost.
25
+
26
+
If you haven't already done so you need to install the dependencies by running:
27
+
28
+
```
29
+
npm install
30
+
```
31
+
32
+
To see the app running in a browser, open a *separate* terminal/command line tab or window, then
33
+
run `npm start` to start the web server. Now, open a browser window for the app and navigate to
This code downloads the `angular.js` script and registers a callback that will be executed by the
120
82
browser when the containing HTML page is fully downloaded. When the callback is executed, Angular
@@ -171,16 +133,17 @@ and one static binding, and our model is empty. That will soon change!
171
133
172
134
## What are all these files in my working directory?
173
135
174
-
Most of the files in your working directory come from the [angular-seed project](https://github.com/angular/angular-seed) which is typically used to bootstrap
175
-
new Angular projects. The seed project includes the latest Angular libraries, test libraries,
176
-
scripts and a simple example app, all pre-configured for developing a typical web app.
136
+
137
+
Most of the files in your working directory come from the [angular-seed project][angular-seed] which
138
+
is typically used to bootstrap new Angular projects. The seed project is pre-configured to install
139
+
the angular framework (via `bower`) and tools for developing a typical web app (via `npm`).
177
140
178
141
For the purposes of this tutorial, we modified the angular-seed with the following changes:
179
142
180
143
* Removed the example app
181
144
* Added phone images to `app/img/phones/`
182
145
* Added phone data files (JSON) to `app/phones/`
183
-
* Added [Bootstrap](http://getbootstrap.com) files to `app/css/` and `app/img/`
146
+
* Added a dependency on [Bootstrap](http://getbootstrap.com) in the `bower.json` file.
184
147
185
148
186
149
@@ -199,9 +162,5 @@ Now let's go to {@link step_01 step 1} and add some content to the web app.
199
162
200
163
<ul doc-tutorial-nav="0"></ul>
201
164
202
-
<div style="display: none">
203
-
Note: During the bootstrap the injector and the root scope will then be associated with the
204
-
element on which the `ngApp` directive was declared, so when debugging the app you can retrieve
205
-
them from browser console via `angular.element(rootElement).scope()` and
0 commit comments