Az alábbi feladat hogy nézne ki megoldva?
Vue.js Exam practice
Create a Todo application using Vue.js where the user can manage their todo items by creating new ones, edit or delete items, and mark them as completed. All todo items should have 3 properties: id, title, completed (boolean).
# Task 1 - Form
Create a form for creating new or editing old todo items.
- The form should have a label, a text area, and a submit button.
- The Todo text is required. When the user submits the form validate the text area and show a red error message to the user if there's any.
# Task 1.1 - Create form
The form should support two flows: one for creating new todo items and one for editing old ones. When the form is in create flow:
- The label in the form should have the text: 'New todo'.
- The text on the submit button should be 'Create'.
- When the user submits the form and the validation passes add a new todo object to the end of the list.
- Reset the text area.
# Task 1.2 - Edit form
When the form is in edit flow:
- The label in the form should have the text: 'Editing {item}'. Where the item is the edited todo's old text value.
- The text on the submit button should be 'Update'.
- The default value of the text area should be the edited item's text.
- When the user submits the form and the validation passes update the old todo text with the new one.
- Reset the text area.
- Reset the form to create flow.
# Task 2 - Todo list
Show the todo items under the form. The items should show the following:
- Checkbox that shows whenever the todo item is completed or not.
- Text of the todo item.
- When the task is completed the text should be crossed by a line.
- Clicking the text should also change the state of the checkbox
- Edit button that starts an edit flow on the form.
- Delete button that removes the clicked item from the list.
# Task 3 (optional) - Styling
Add custom styles to the application.
A legnagyobb probléma, hogy
"When the form is in edit flow:
The label in the form should have the text: 'Editing {item}'. Where the item is the edited todo's old text value." jelenljen meg ez a rész?
További kérdések:
Minden jog fenntartva © 2024, www.gyakorikerdesek.hu
GYIK | Szabályzat | Jogi nyilatkozat | Adatvédelem | Cookie beállítások | WebMinute Kft. | Facebook | Kapcsolat: info(kukac)gyakorikerdesek.hu
Ha kifogással szeretne élni valamely tartalommal kapcsolatban, kérjük jelezze e-mailes elérhetőségünkön!