!important in :style="{}" #4473
Replies: 3 comments
-
I don't think that syntax is supported (it only works with classes). |
Beta Was this translation helpful? Give feedback.
-
This is limited by how the CSS api works on elements. https://developer.mozilla.org/en-US/docs/Web/API/CSSStyleDeclaration/setProperty So the object is basically mapped to the I could see a way to support it by having keys that start with |
Beta Was this translation helpful? Give feedback.
-
Well, a workaround to use a variable with an !important style is to use :style as a string |
Beta Was this translation helpful? Give feedback.
-
It seems not to work to use !important in this kind of code:
:style="{color:'red !important'}"
Is there any way to make it work?
Should be a good feature to make it work otherwise
Beta Was this translation helpful? Give feedback.
All reactions