-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
43 lines (35 loc) · 850 Bytes
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>Vue Template</title>
<link href="style.css" rel="stylesheet" type="text/css" />
<script src="https://unpkg.com/vue@next"></script>
</head>
<body>
<h1>Build An Interactive To Do List</h1>
<div id="todo-list">
<form v-on:submit.prevent="addNewTask">
<label for="task-input">Add a new task</label>
<input
v-model="newTask"
id="task-input"
placeholder="Eg. Watch Vue course"
/>
<button >Submit</button>
</form>
<ul>
<todo-item
v-for="(task, index) in tasks"
:key="task.id"
:title="task.title"
@remove="tasks.splice(index, 1)"
>
</todo-item>
</ul>
</div>
<script src="script.js">
</script>
</body>
</html>