javascript - Class Binding ternary operator - Stack Overflow

PHOTO EMBED

Mon Sep 13 2021 13:19:35 GMT+0000 (UTC)

Saved by @arielvol #javascript

:class="sportTypes.sports.indexOf(sport) > -1 ? 'is-primary' : 'is-outlined'"
content_copyCOPY

https://stackoverflow.com/questions/41969302/class-binding-ternary-operator