doc(CheatSheet): update ngSwitch syntax in the cheatsheet (#9361)

This commit is contained in:
Jesús Rodríguez 2016-06-20 17:05:50 +02:00 committed by Victor Berchet
parent 7a3689f175
commit 65be81baf8
1 changed files with 3 additions and 3 deletions

View File

@ -21,10 +21,10 @@ Turns the li element and its contents into a template, and uses that to instanti
@cheatsheetItem
syntax:
`<div [ngSwitch]="conditionExpression">
<template [ngSwitchWhen]="case1Exp">...</template>
<template ngSwitchWhen="case2LiteralString">...</template>
<template [ngSwitchCase]="case1Exp">...</template>
<template ngSwitchCase="case2LiteralString">...</template>
<template ngSwitchDefault>...</template>
</div>`|`[ngSwitch]`|`[ngSwitchWhen]`|`ngSwitchWhen`|`ngSwitchDefault`
</div>`|`[ngSwitch]`|`[ngSwitchCase]`|`ngSwitchCase`|`ngSwitchDefault`
description:
Conditionally swaps the contents of the div by selecting one of the embedded templates based on the current value of conditionExpression.