add:添加预览逻辑
This commit is contained in:
5
package-lock.json
generated
5
package-lock.json
generated
@ -2401,8 +2401,9 @@
|
||||
},
|
||||
"node_modules/lodash": {
|
||||
"version": "4.17.21",
|
||||
"resolved": "https://registry.npmmirror.com/lodash/-/lodash-4.17.21.tgz",
|
||||
"integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg=="
|
||||
"resolved": "https://repo.bingosoft.net/repository/npm/lodash/-/lodash-4.17.21.tgz",
|
||||
"integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==",
|
||||
"license": "MIT"
|
||||
},
|
||||
"node_modules/lsp-uuid": {
|
||||
"version": "3.2.0",
|
||||
|
||||
27
preview/views/Preview.vue
Normal file
27
preview/views/Preview.vue
Normal file
@ -0,0 +1,27 @@
|
||||
<template>
|
||||
<div v-if="!isEmpty(data)" class="box">
|
||||
<template v-for="item in data" :key="item.id">
|
||||
<!-- <component :is="componentsList[item.code]" :data="item"></component>-->
|
||||
</template>
|
||||
</div>
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
import {onBeforeMount, shallowRef, ref} from "vue";
|
||||
import {isEmpty} from "lodash";
|
||||
import _ from "lodash";
|
||||
|
||||
const data = shallowRef<any>({});
|
||||
onBeforeMount(() => {
|
||||
// 接收客户端posemessage传递过来的消息
|
||||
const obj = JSON.parse(localStorage.getItem("lowcode") || "");
|
||||
console.log("数据哈哈哈", obj);
|
||||
data.value = obj;
|
||||
});
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.box {
|
||||
width: 1000px;
|
||||
height: 600px;
|
||||
overflow: hidden;
|
||||
}
|
||||
</style>
|
||||
Reference in New Issue
Block a user