Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
<input type="text" [(ngModel)]="todo" class="form-control" />
<hr />
<button class="btn btn-primary btn-block" (click)="aFireService.add(todo); todo = ''">AÑADIR TODO</button>
<hr />
<div *ngIf="(todos | async); let data">
<table class="table" *ngIf="data.length > 0">
<tr *ngFor="let todo of data">
<td>{{ }}</td>
<td>{{ todo.todo }}</td>
<button class="btn btn-danger" (click)="aFireService.remove(">DELETE</button>
<div *ngIf="data.length === 0" class="alert alert-danger text-center">NO HAY TODOS</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.