-
Notifications
You must be signed in to change notification settings - Fork 0
/
minion.html
63 lines (55 loc) · 1.28 KB
/
minion.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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
<!doctype html>
<style>
[v-cloak] {
display: none;
}
</style>
<link rel="stylesheet" type="text/css" href="slick/slick.css"/>
<link rel="stylesheet" type="text/css" href="slick/slick-theme.css"/>
<div id="app">
<div v-cloak>
<spiel inline-template>
<div>
<ol>
<li v-for="tier in tiere">
{{ tier }}
</li>
</ol>
<button class="btn btn-primary" @click="mehr">Knopf</button>
<h1 v-if="zahl">Hallo {{ zahl }}</h1>
<input type="text" v-model="zahl">
<div v-if="zahl == 10">
<img src="bilder/minion.gif" alt="">
</div>
</div>
</spiel>
</div>
</div>
<script src="https://cdnjs.cloudflare.com/ajax/libs/vue/2.1.10/vue.js"></script>
<script>
Vue.component('spiel', {
props: [],
data: function() {
return {
tiere: [
'Esel',
'Hund',
]
}
},
mounted: function() {
this.spielStarten();
},
methods: {
spielStarten: function () {
},
mehr: function () {
this.zahl = this.zahl *1 +1;
}
},
});
new Vue({
el: '#app'
});
Vue.config.devtools = true;
</script>