[Vuejs]-Passing a property to a slot

0๐Ÿ‘

A slot is for uncoupled content. Your requirement is that the content be a component that takes a prop. It seems to me that what you want to do is pass the child component to the parent as a prop, and have the parent template do something like

<div :is="childComponent" :x="child.x"></div>

Leave a comment