Skip to content

Instantly share code, notes, and snippets.

@softwarejc

softwarejc/hello.view.html Secret

Created Jan 24, 2016
Embed
What would you like to do?
<div style="background: ghostwhite">
<h3>
<label>Name:</label>
<!--binding to component field-->
<input type="text" [(ngModel)]="name" placeholder="Enter a name here">
<!--binding click event to component method-->
<button class="btn btn-primary col-md-2" (click)="sayHello()">
Hello!
</button>
</h3>
<!-- conditionally display `message` -->
<h4 [hidden]="!message">{{message}}</h4>
</div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.