diff --git a/src/app/app.component.html b/src/app/app.component.html index 2ec8989..a16363e 100644 --- a/src/app/app.component.html +++ b/src/app/app.component.html @@ -9,7 +9,7 @@
- + diff --git a/src/app/app.component.ts b/src/app/app.component.ts index bdc8370..a7869a0 100644 --- a/src/app/app.component.ts +++ b/src/app/app.component.ts @@ -28,7 +28,7 @@ export class AppComponent implements OnInit { if (this.inputValue && !listOfTodoText.includes(this.inputValue)) { this.list.push(new TodoItem(this.inputValue)) this.inputValue = ""; - this.saveList(); + this.saveList() } } @@ -38,7 +38,7 @@ export class AppComponent implements OnInit { */ removeItem(toRemove: TodoItem): void { this.list = this.list.filter(item => item !== toRemove); - this.saveList(); + this.saveList() } /** @@ -46,11 +46,11 @@ export class AppComponent implements OnInit { */ removeCheckedItems(): void { this.list = this.list.filter(item => !item.checked) - this.saveList(); + this.saveList() } - private saveList(): void { + saveList(): void { LocalService.saveData(this.LOCAL_STORAGE_KEY, this.list); + console.log(this.list) } - }