ratiw / vuetable-2-tutorial

MIT License
258 stars 67 forks source link

lesson 12 - Detail row without registering component globally? #58

Closed alperencaliskan closed 7 years ago

alperencaliskan commented 7 years ago

Hello, is there any way to pass local imported component to "detail-row-component" without registering component globally as in the lesson? code from lesson 12

<script>
    //...
    import DetailRow from './DetailRow'

    Vue.component('my-detail-row', DetailRow)   // <--- register the component to Vue
    //...

</script>
ratiw commented 7 years ago

No. But you can use scoped slot instead.

alperencaliskan commented 7 years ago

I will look into that. Thank you.

alperencaliskan commented 7 years ago

It worked! And with one less component. Thank you.