docs(aio): final migration from old site
This commit is contained in:

committed by
Pete Bacon Darwin

parent
8f1359d25f
commit
061475402c
@ -48,11 +48,11 @@
|
||||
<!-- #enddocregion display-none -->
|
||||
|
||||
<h4>NgIf with template</h4>
|
||||
<p><template> element</p>
|
||||
<p><ng-template> element</p>
|
||||
<!-- #docregion ngif-template -->
|
||||
<template [ngIf]="hero">
|
||||
<ng-template [ngIf]="hero">
|
||||
<div>{{hero.name}}</div>
|
||||
</template>
|
||||
</ng-template>
|
||||
<!-- #enddocregion ngif-template -->
|
||||
|
||||
<p>template attribute</p>
|
||||
@ -140,9 +140,9 @@
|
||||
<!--#enddocregion inside-ngfor -->
|
||||
<p class="code"><template ngFor let-hero [ngForOf]="heroes" let-i="index" let-odd="odd" [ngForTrackBy]="trackById"></p>
|
||||
<!--#docregion inside-ngfor -->
|
||||
<template ngFor let-hero [ngForOf]="heroes" let-i="index" let-odd="odd" [ngForTrackBy]="trackById">
|
||||
<ng-template ngFor let-hero [ngForOf]="heroes" let-i="index" let-odd="odd" [ngForTrackBy]="trackById">
|
||||
<div [class.odd]="odd">({{i}}) {{hero.name}}</div>
|
||||
</template>
|
||||
</ng-template>
|
||||
<!--#enddocregion inside-ngfor -->
|
||||
|
||||
</div>
|
||||
@ -179,21 +179,21 @@
|
||||
</div>
|
||||
<!-- #enddocregion ngswitch-template-attr -->
|
||||
|
||||
<h4>NgSwitch with <template></h4>
|
||||
<h4>NgSwitch with <ng-template></h4>
|
||||
<!-- #docregion ngswitch-template -->
|
||||
<div [ngSwitch]="hero?.emotion">
|
||||
<template [ngSwitchCase]="'happy'">
|
||||
<ng-template [ngSwitchCase]="'happy'">
|
||||
<happy-hero [hero]="hero"></happy-hero>
|
||||
</template>
|
||||
<template [ngSwitchCase]="'sad'">
|
||||
</ng-template>
|
||||
<ng-template [ngSwitchCase]="'sad'">
|
||||
<sad-hero [hero]="hero"></sad-hero>
|
||||
</template>
|
||||
<template [ngSwitchCase]="'confused'">
|
||||
</ng-template>
|
||||
<ng-template [ngSwitchCase]="'confused'">
|
||||
<confused-hero [hero]="hero"></confused-hero>
|
||||
</template >
|
||||
<template ngSwitchDefault>
|
||||
</ng-template >
|
||||
<ng-template ngSwitchDefault>
|
||||
<unknown-hero [hero]="hero"></unknown-hero>
|
||||
</template>
|
||||
</ng-template>
|
||||
</div>
|
||||
<!-- #enddocregion ngswitch-template -->
|
||||
|
||||
@ -202,9 +202,9 @@
|
||||
<h2><template></h2>
|
||||
<!-- #docregion template-tag -->
|
||||
<p>Hip!</p>
|
||||
<template>
|
||||
<ng-template>
|
||||
<p>Hip!</p>
|
||||
</template>
|
||||
</ng-template>
|
||||
<p>Hooray!</p>
|
||||
<!-- #enddocregion template-tag -->
|
||||
|
||||
@ -242,9 +242,9 @@
|
||||
(A) <p template="myUnless condition" class="code unless">
|
||||
</p>
|
||||
|
||||
<template [myUnless]="condition">
|
||||
<ng-template [myUnless]="condition">
|
||||
<p class="code unless">
|
||||
(A) <template [myUnless]="condition">
|
||||
</p>
|
||||
</template>
|
||||
</ng-template>
|
||||
|
||||
|
Reference in New Issue
Block a user