So i have made this code, and it works as it should
<tr
v-for="(day, index) in days"
:key="index"
:class="[
{ no_target: day.date.format('dddd') == 'Sunday' || day.date.format('dddd') == 'Saturday' },
{ active: moment == day.date.format('Do dddd') },
]"
class="calendar-row"
>
This is adds the class of no_target to weekend days and active to todays date. However my boss thinks this is too much logic inside of a class and would like me to move it to method or computed property. I cannot really seem to think of a solution for this.
any of you sharp minds here got a solution for this?
I think using a method like this could help
so you can do this