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.
Copy file name to clipboardExpand all lines: public/docs/ts/latest/guide/style-guide.jade
+17-33Lines changed: 17 additions & 33 deletions
Original file line number
Diff line number
Diff line change
@@ -243,16 +243,17 @@ a(href="#toc") Back to top
243
243
:marked
244
244
**Why?** The `Component` suffix is more commonly used and is more explicitly descriptive.
245
245
246
-
```
247
-
/* recommended */
248
-
AppComponent // app.component.ts
249
-
HeroesComponent // heroes.component.ts
250
-
HeroListComponent // hero-list.component.ts
251
-
HeroDetailComponent // hero-detail.component.ts
246
+
:marked
247
+
```
248
+
/* recommended */
249
+
AppComponent // app.component.ts
250
+
HeroesComponent // heroes.component.ts
251
+
HeroListComponent // hero-list.component.ts
252
+
HeroDetailComponent // hero-detail.component.ts
252
253
253
-
/* recommended */
254
-
ValidationDirective // validation.directive.ts
255
-
```
254
+
/* recommended */
255
+
ValidationDirective // validation.directive.ts
256
+
```
256
257
257
258
a(href="#toc") Back to top
258
259
@@ -286,6 +287,7 @@ a(href="#toc") Back to top
286
287
:marked
287
288
**Why?** Service names such as `Credit` are nouns and require a suffix and should be named with a suffix when it is not obvious if it is a service or something else.
288
289
290
+
:marked
289
291
```
290
292
HeroDataService // hero-data.service.ts
291
293
CreditService // credit.service.ts
@@ -415,6 +417,7 @@ a(href="#toc") Back to top
415
417
:marked
416
418
**Why?** Provides a consistent way to quickly identify and reference pipes.
417
419
420
+
:marked
418
421
```
419
422
EllipsisPipe // ellipsis.pipe.ts
420
423
InitCapsPipe // init-caps.pipe.ts
@@ -444,6 +447,7 @@ a(href="#toc") Back to top
444
447
:marked
445
448
**Why?** Provides pattern matching for [karma](http://karma-runner.github.io/) or other test runners.
446
449
450
+
:marked
447
451
```
448
452
// recommended
449
453
@@ -483,6 +487,7 @@ a(href="#toc") Back to top
483
487
:marked
484
488
**Why?** Provides pattern matching for test runners and build automation.
485
489
490
+
:marked
486
491
```
487
492
// recommended
488
493
app.e2e-spec.ts
@@ -1547,32 +1552,11 @@ a(href="#toc") Back to top
1547
1552
:marked
1548
1553
**Why?** The metadata declaration attached to the directive is shorter and thus more readable.
0 commit comments