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 Dec 4, 2017. It is now read-only.
The [QuickStart](../quickstart.html "Angular QuickStart") sample only shows the `AppComponent` file.
80
-
It creates the equivalent of `app.module.ts` and `main.ts` internally _for that example only_
81
-
so the reader can discover Angular without distraction.
82
-
83
-
All other guides and cookbooks expect you to have defined these three files explicitly.
84
-
Each file has a distinct purpose and evolves independently as the application grows.
75
+
All guides and cookbooks have _at least these three files_. Each file has a distinct purpose and evolves independently as the application grows.
85
76
86
77
style td, th {vertical-align: top}
87
78
table(width="100%")
@@ -94,31 +85,34 @@ table(width="100%")
94
85
td <code>app.component.ts</code>
95
86
td
96
87
:marked
97
-
Defines the same `AppComponent` as the one in the [QuickStart](../quickstart.html).
88
+
Defines the same `AppComponent` as the one in the QuickStart playground.
98
89
It is the **root** component of what will become a tree of nested components
99
90
as the application evolves.
100
91
tr
101
92
td <code>app.module.ts</code>
102
93
td
103
94
:marked
104
-
Defines `AppModule`, the [root module](appmodule.html) that tells Angular how to assemble the application.
95
+
Defines `AppModule`, the [root module](appmodule.html "AppModule: the root module") that tells Angular how to assemble the application.
105
96
Right now it declares only the `AppComponent`.
106
97
Soon there will be more components to declare.
107
98
tr
108
99
td <code>main.ts</code>
109
100
td
110
101
:marked
111
102
Compiles the application with the [JiT compiler](../glossary.html#jit)
112
-
and [bootstraps](appmodule.html#main) the application to run in the browser.
103
+
and [bootstraps](appmodule.html#main "bootstrap the application") the application to run in the browser.
113
104
That's a reasonable choice for the development of most projects and
114
105
it's the only viable choice for a sample running in a _live-coding_ environment like Plunker.
115
106
You'll learn about alternative compiling and deployment options later in the documentation.
116
107
117
-
.l-main-section
118
-
:marked
119
-
## Next Step
108
+
.l-sub-section
109
+
:marked
110
+
### Next Step
111
+
112
+
If you're new to Angular, we recommend staying on the [learning path](learning-angular.html).
120
113
121
-
If you're new to Angular, try the recommended [learning path](learning-path.html).
114
+
br
115
+
br
122
116
123
117
a#install-node
124
118
.l-main-section
@@ -140,3 +134,31 @@ a#install-node
140
134
You may need [nvm](https://github.com/creationix/nvm) if you already have projects running on your machine that
141
135
use other versions of node and npm.
142
136
137
+
a#why-locally
138
+
.l-main-section
139
+
:marked
140
+
## Appdendix: Why develop locally
141
+
142
+
<live-example>Live coding</live-example> in the browser is a great way to explore Angular.
143
+
144
+
Links on almost every documentation page open completed samples in the browser.
145
+
You can play with the sample code, share your changes with friends, and download and run the code on your own machine.
146
+
147
+
The [QuickStart](../quickstart.html "Angular QuickStart Playground") shows just the `AppComponent` file.
148
+
It creates the equivalent of `app.module.ts` and `main.ts` internally _for the playground only_.
149
+
so the reader can discover Angular without distraction.
150
+
The other samples are based on the QuickStart seed.
151
+
152
+
As much fun as this is ...
153
+
* you can't ship your app in plunker
154
+
* you aren't always online when writing code
155
+
* transpiling TypeScript in the browser is slow
156
+
* the type support, refactoring, and code completion only work in your local IDE
157
+
158
+
Use the <live-example><i>live coding</i></live-example> environment as a _playground_,
159
+
a place to try the documentation samples and experiment on your own.
160
+
It's the perfect place to reproduce a bug when you want to
161
+
<a href="https://github.com/angular/angular.io/issues/new" target="_blank" title="File a documentation issue">file a documentation issue</a> or
162
+
<a href="https://github.com/angular/angular/issues/new" target="_blank" title="File an Angular issue">file an issue with Angular itself</a>.
163
+
164
+
For real development, we strongly recommend [developing locally](#develop-locally).
0 commit comments