object type color property not work
mikeda37 opened this issue · 5 comments
Hi,
The object-type color property looks like not working.
Example: {checked: '#00FF00', unchecked: '#FF0000, disabled: '#CCCCCC'}
Could you check it out?
Thanks
Hey @mikeda37 , What do you mean by not working? Did you get any error message or smth?
I didn't get any errors.
color="{checked: '#00FF00', unchecked: '#FF0000, disabled: '#CCCCCC'}"
does just not work while color="#00FF00"
works.
to bind variables in vue js you have to either use v-bind:color="{}"
or :color="{}"
I realized a single quote around the color code is missing with your Example and I just copied it.
Now I confirmed it works with colon.
However, I wonder why switchColor="{checked: '#00FF00', unchecked: '#FF0000', disabled: '#CCCCCC'}"
works without colon.
Thanks anyway.
You are welcome 😉