How to change the color of a tag (dropdown) based on the value of another field in the same row?

I can use JS to set the color of a tag based on it's content. However, I would like to set that color based on the content of another column in that row, but I cannot figure out what to use to evaluate this value in another column on the same row.

{{currentRow.somecolumn === 'something'?'blue':'red'}}

Thanks for the quick response, I tried that, but it gives me grey ...

Can you share a screenshot and some more detail?

What I am trying to do is show the STATUS column with a green background when the value of the Bedrag. column > 0 and otherwise (< 0) show the background of the STATUS column in red. The if does resolve to the right color number but it does not change i.e. goes to grey,

Using item it works as expected, but I need the value of the trxAmount to determine the color.

There is another post about this being either deprecated, worked on or another workaround for it. I'll try and find it and post the link here.

Hey folks! Just want to mention that this should behave properly in the new table component: