I used a component inside the project to display the input, and I wrote that component as follows, both to add "task" and to edit it.