-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathapp.js
59 lines (52 loc) · 1.14 KB
/
app.js
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
var app=new Vue({
el: '#app',
data: {
log:{
x:0,
y:0,
},
count: 0,
link: 'https://www.google.com',
message: 'Hello Vue!',
welcome: 'Welcome to Vue.js',
classes: ['one', 'two'],
name: 'Sajeeb Chakraborty',
items:[
{name: 'item1', price: 100, quantity: 10},
{name: 'item2', price: 200, quantity: 20},
{name: 'item3', price: 300, quantity: 30},
]
},
methods: {
myOutcome() {
return "good";
},
myAge() {
return `${this.welcome} . good`;
},
myAge2(age) {
return `${age} . good`;
},
amount(data)
{
return this.count+=data;
},
over(event)
{
this.log.x=event.offsetX;
this.log.y=event.offsetY;
},
show(e)
{
console.log(e.target.value);
},
show2(e)
{
console.log(e.target.value);
},
message2()
{
console.log("this is a message");
}
}
})