forked from mrizky-kur/Redux-toolkit
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconditionalRendering.html
More file actions
27 lines (25 loc) · 874 Bytes
/
conditionalRendering.html
File metadata and controls
27 lines (25 loc) · 874 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
<template>
<lightning-card title="Conditional Rendering">
<div class="slds-m-around_medium">
<lightning-button variant="brand"
label="Show Data"
title="SHow Data"
onclick={handleClick}
class="slds-m-left_x-small"></lightning-button>
<template if:true={isVisible}>
<div>Welcome to My App Page</div>
</template>
<template if:false={isVisible}>
<div>To see the data press the button.</div>
</template>
<lightning-input
type="text"
label="Type 'Hello' to see data"
onkeyup={changeHandler}>
</lightning-input>
<template if:true={helloText}>
<div>Hurray!! You entered the text correctly.</div>
</template>
</div>
</lightning-card>
</template>