-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
30 lines (30 loc) · 922 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Lite Vue</title>
</head>
<body>
<script type="module">
import {createApp} from "./src/lite-vue.js"
const app = createApp({
open: true,
msg: "show meee !!",
color: "red",
changeColor(newColor){
this.color = newColor;
}
});
app.mount("#app");
</script>
<div id="app">
<div v-if="open">{{msg}} deneme seçili renk {{color}}</div>
<div :style="'color:' + color" @click="changeColor('red')">Red</div>
<div :style="'color:' + color" @click="changeColor('blue')">Blue</div>
<button @click="open = !open">Toggle</button>
<div v-text="msg"></div>
<input type ="text" v-model="msg" />
</div>
</body>
</html>