I have a situation where I want to have computed local subcomponents. My specific case is the cell components of a row of user data data. Something like that:
var DataGridRow = {
props: ['columns'],
template: '<tr><component v-for="col in columns" :is="col.component"></component></tr>',
components: function () {
var comps = {};
return comps;
}
}
In my tests, this did not work.
Does this exist and is not documented, and am I doing it wrong?
If not, is it logical to implement this?
Otherwise, is there a better solution without declaring global components?
EDIT: also discussed here: https://github.com/vuejs/vue/issues/4651
source
share