[Proposal] Shorthand for setting classes and inline styles using argments #14338
rosyatrandom
started this conversation in
Ideas
Replies: 1 comment
-
|
Hey @rosyatrandom, Working with Vue reactivity system and compilers can sometimes present interesting edge cases. A few quick things to consider regarding this topic:
I highly recommend checking out the Vue DevTools extension to inspect the component tree and verify if the state is updating as expected. Let me know if you want to dig deeper into the specific component logic. Hope this points you in the right direction! Let me know how it goes. Happy coding! |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Simply because setting conditional classes and individual inline styles are both slightly annoying, I propose a completely unnecessary shorthand:
You're asking 'BUT WHY?'
The answer is purely: I just prefer it slightly. Sorry.
And if we were to take this all seriously, for some reason, a shorthand for
class:fooandstyle:barwould be nice. Looking at readily available symbols, let's just say^fooand$barfor the example:<AnyElement $some-prop="some-val" ^some-class="some-predicate"/>Beta Was this translation helpful? Give feedback.
All reactions