VueJS - v-bind:style + hover

后端 未结 6 2048
佛祖请我去吃肉
佛祖请我去吃肉 2021-01-01 12:27

I need to use CSS hover with VueJS v-bind:style directive but couldn\'t find information regarding it.

I need to bind styles for hover but v-bind:style.hover=

6条回答
  •  粉色の甜心
    2021-01-01 12:52

    You can assign your Vuejs Component an id and apply the required hover style in a stylesheet.

    
    

    then in tag,

    
    

    If you want the hover style to contain any dynamic data. make a tag that calls a computed property.

    
    

提交回复
热议问题