vc-portal

Portal, like https://github.com/react-component/portal, base on portal-vue

Usage no npm install needed!

<script type="module">
  import vcPortal from 'https://cdn.skypack.dev/vc-portal';
</script>

README

VcPortal

rc-util 中关于 Portal 的 Vue 实现。

Props

参数 说明 类型 默认值
getContainer 获取承载的容器元素 Function() : HTMLElement -
didUpdate 每次更新后的执行的回调函数 Function() -
targetClass 传送后的目标的样式 string/object/array -
provide 向子孙提供一些东西 object/function -

Slots

插槽 说明
default 默认插槽,内容为传送后的目标