-
Notifications
You must be signed in to change notification settings - Fork 16
/
Copy pathApp.vue
63 lines (62 loc) · 1.42 KB
/
App.vue
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
<!--
* @Author: h7ml
* @Date: 2021-11-22 14:12:45
* @LastEditors: h7ml
* @LastEditTime: 2021-11-22 14:12:45
* @Description:
* @FilePath: examples\App.vue
* @DocumentLink:
-->
<template>
<div id="app">
<dgiot-amis-editor
theme="ang"
class-name="is-fixed"
:is-mobile="isMobile"
:preview="isPreview"
:value="schema"
@onChange="onChange"
/>
</div>
</template>
<script>
export default {
name: 'App',
components: {},
data() {
return {
isPreview: false,
isMobile: false,
post: {
json: '',
amis_page_id: 15,
},
baseURL: 'https://prod.iotn2n.com',
schema: {},
}
},
computed: {},
mounted() {},
beforeCreate() {}, //生命周期 - 创建之前
beforeMount() {}, //生命周期 - 挂载之前
beforeUpdate() {}, //生命周期 - 更新之前
updated() {}, //生命周期 - 更新之后
beforeDestroy() {}, //生命周期 - 销毁之前
destroyed() {}, //生命周期 - 销毁完成
activated() {},
methods: {
onChange(e) {
console.log('onChange', e)
},
}, //如果页面有keep-alive缓存功能,这个函数会触发
}
</script>
<style lang="scss">
#app {
font-family: Avenir, Helvetica, Arial, sans-serif;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
text-align: center;
color: #2c3e50;
}
</style>