Ejercicio input output#4
Open
pablo-nardi wants to merge 4 commits intoutnfrrottads:mainfrom
Open
Conversation
aotaduy
reviewed
May 27, 2021
| this.lastId = this.lastId + 1; | ||
| } | ||
| taskRemoved(event: TodoItem){ | ||
| for(let i = 0; i<this.list.length; i++){ |
Contributor
There was a problem hiding this comment.
aca podes usar findIndex o algun metodo mejor para encontrar el indice y poder eliminarla
aotaduy
reviewed
May 27, 2021
| this.oCont.emit(Input.value); | ||
| this.todoApp?.add(Input.value); | ||
| this.addTask.emit(Input.value); | ||
| Input.value = ''; |
Contributor
There was a problem hiding this comment.
las variables siempre en minuscula y camelcase, usamos el standard de airbnb
aotaduy
approved these changes
May 27, 2021
Contributor
|
No logro ver en el PR como tenes artmado el tema de los templates como tenes conectado el app con el form ? |
Contributor
|
Lo que tenes que hacer es conectar el output del todo-form con el metodo addTask de tu appcomponent lo que seria en el app.component.html
No se si matchean los parametros de lo que mandas en el emit de todo-form con lo que esperas recibir pero va por ahi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Profe le hago este pull requeste porque no se como logar que se comuniquen los componentes hijos
Osea como comunicar el componente "todo-form" con "todo-app".
Yo intenté hacer "todo-form" le pase la info al padre y despues el padre a "todo-app" pero no se como tomarla desde "todo-app" para agregarla al array y mostrarla con el *ngfor.