forked from zhangchunlin/webpack_tutorial
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathapp.vue
More file actions
36 lines (36 loc) · 784 Bytes
/
app.vue
File metadata and controls
36 lines (36 loc) · 784 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
<template>
<div>
<div>Hello {{ name }}</div>
<v-title title="Vue组件化"></v-title>
<v-button @click="handleClick">点击按钮</v-button>
<p>
<img src="./images/image.jpeg" style="width: 200px;">
</p>
</div>
</template>
<script>
import vTitle from './title.vue';
import vButton from './button.vue';
export default {
components: {
vTitle,
vButton
},
data() { // es6 函数简写
return {
name: 'Vue.js'
}
},
methods: {
handleClick (e) {
console.log(e);
}
}
}
</script>
<style scoped>
div{
color: #f60;
font-size: 24px;
}
</style>