|
Menu
×
×
正确!
VUE - 代码练习:需要哪些指令来将数据从组件槽提供给父级? Local data in a component is sent from a slot with @(6), and it can be received in the parent with @(6). CompOne.vue: <slot @(6):lclData="data"></slot> App.vue: <comp-one @(6):"dataFromSlot"> <h2>{{ dataFromSlot.lclData }}</h2> </comp-one> Local data in a component is sent from a slot with v-bind, and it can be received in the parent with v-slot. CompOne.vue: <slot v-bind:lclData="data"></slot> App.vue: <comp-one v-slot:"dataFromSlot"> <h2>{{ dataFromSlot.lclData }}</h2> </comp-one> Local data in a component is sent from a slot with v-bind, and it can be received in the parent with v-slot. CompOne.vue: <slot :lclData="data"></slot> App.vue: <comp-one v-slot:"dataFromSlot"> <h2>{{ dataFromSlot.lclData }}</h2> </comp-one> 不正确点击 这里 再试一次。 正确!下一个 ❯ |
这将重置所有 88 个练习测验的分数。
您确定要继续吗?