-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex3.html
More file actions
38 lines (32 loc) · 900 Bytes
/
index3.html
File metadata and controls
38 lines (32 loc) · 900 Bytes
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
<html>
<head>
<script type="text/javascript" src='vue.js'></script>
</head>
<style type="text/css">
.completed {text-decoration: line-through;}
</style>
<body>
<div id="app">
<tasks :list="tasks"></tasks>
<ul>
<li v-for="numb in filteredNumbers">{{numb.name}}</li>
</ul>
</div>
<template id="tasks-template">
<div>
<h1>My tasks</h1>
<h4>Total uncompleted: <span v-show='remaining'>{{ remaining }}</span></h4>
<ul v-if="list.length">
<li v-for="item in list">
<span @click="item.completed = !item.completed" :class="{'completed' : item.completed}">{{item.body}}</span>
<strong @click="deleteTask(item)">x</strong>
</li>
</ul>
<h4 v-else>Brak zadan</h4>
<input @keyup.enter="addTask(this.value)"/><br>
<button @click="clearCompleted">Wyczysc ukoncozne zadania</button>
</div>
</template>
<script type="text/javascript" src="main1.js"></script>
</body>
</html>