vue: passing props down to all descendants

后端 未结 6 1096
夕颜
夕颜 2021-01-22 18:36

I have a parent component with the following line


6条回答
  •  野趣味
    野趣味 (楼主)
    2021-01-22 19:12

    for vue > 2.0

    v-bind="$attrs" it's sufficient, or you can declare them at data(), with [this.$attrs]

提交回复
热议问题