Font color in List Node

I'm using a function node to send an array of data to a list node.
My goal is for the description color to change based on the value.

Here's my function node code:

var array = flow.get('DevStat')
var combo = [{}]
var single = {}

for(let i=0;i<1000;i++){
//single = ={"title":"EndPoint","description":"This is description of <font color="red">Apple.","icon":""}
single ={}
if (array[i] === 0)
single.description = "<font color="white"> "
else if (array[i] === 1)
single.description = "<font color="yellow"> "
single.description = "<font color="red">"

single.title =  "EndPoint"

single.description += i.toString(10)


msg.payload = combo

return msg;

And the result looks like this

As you see, the color control prints and the color does not change.

Is there a way to make this work?

I solved this by enabling HTML in the LIST node.

Speaking of esthetics :stuck_out_tongue: You should be formatting posted code using the </> icon so we can all tell the difference between code and post commentary.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.