mirror of
https://gitee.com/element-plus/element-plus.git
synced 2024-12-15 01:41:20 +08:00
22 lines
419 B
Vue
22 lines
419 B
Vue
|
<script setup lang="ts">
|
||
|
import { computed } from 'vue'
|
||
|
import ApiTyping from './vp-api-typing.vue'
|
||
|
|
||
|
const props = defineProps({
|
||
|
type: {
|
||
|
type: String,
|
||
|
required: true,
|
||
|
},
|
||
|
shallow: Boolean,
|
||
|
})
|
||
|
|
||
|
const type = computed(() => {
|
||
|
const wrapperType = props.shallow ? 'ShallowRef' : 'Ref'
|
||
|
return `${wrapperType}<${props.type}>`
|
||
|
})
|
||
|
</script>
|
||
|
|
||
|
<template>
|
||
|
<ApiTyping type="Object" :details="type" />
|
||
|
</template>
|