You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
vite-vue3-lowcode/preview/views/comp-render.tsx

28 lines
540 B

import { defineComponent } from 'vue'
export default defineComponent({
name: 'CompRender',
props: {
element: {
type: Object,
default: () => ({})
},
config: {
type: Object,
default: () => ({})
}
},
setup(props) {
return () => {
const component = props.config.componentMap[props.element.componentKey]
return component.render({
size: {},
props: props.element.props || {},
model: {},
block: props.element,
custom: {}
})
}
}
})