Skip to content

Conversation

@PejmanNik
Copy link

Hi
I think this way we can fix the problem you explained in lesson 17
Passing Scoped Slot to MyVuetable in Template by v-for on slotName in Object.keys($scopedSlots)
Thanks for your great Tutorial

Passing Scoped Slot to MyVuetable in Template
@PejmanNik PejmanNik changed the title Update MyVuetable.vue Passing Scoped Slot to MyVuetable in Template Jul 3, 2017
@ratiw
Copy link
Owner

ratiw commented Jul 4, 2017

@PejmanNik That is a really interesting way of passing the scoped slot. Thanks for sharing! :)

@PejmanNik
Copy link
Author

@ratiw Thank you :)

@ghost
Copy link

ghost commented Dec 2, 2017

With Vue 2.5 it's now the way to follow ... thanks
In this case we don't need anymore the CustomAction.vue component

using render function was interesting for better understanding , but should it be now deprecated ?

@ghost
Copy link

ghost commented Dec 2, 2017

to avoid warning binding :key should be added to a wrapper element

     <template :slot="slotName" slot-scope="props" v-for="(slotName, index) in  $scopedSlots?Object.keys($scopedSlots):null">
       <div :key="index">
          <slot :name="slotName" :row-data="props.rowData" :row-index="props.rowIndex" :row-field="props.rowField"></slot>
     </div> 
     </template>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants