0
votes

I've made a dialog with a certain structure that a I want to re-utilize with a form inside of it. This form it's completely variable (it could contain v-text-fields, v-textarea, v-selects, etc...). How can I accomplish that knowing that the dialog is a child element and depends of the parent to know how the form will be?. It's possible to bind an entire component?

<template>
 <!-- someData -->

 <ChildDialog :variableForm="formComponent"/> // Something like that?

 <!-- moreData -->
</template>

Thank you, hope you understand my question.

1
Have you considered using slots? like used here stackoverflow.com/questions/44923775/… - Abdulaziz Yesuf
Thank you!!, that's what I need. I will post this as an answer - Lorenzo Fabro

1 Answers

1
votes

As Abdulaziz Yesuf said, with slots you can accomplish my problem (Passing html into Vue component)