HA Entity Node OutPut On/Off

Anyone know how to make the HA entity node output both an On and Off when toggling the switch. I remembered in the past I thought seeing a JSONATA expression that may do this but cannot seem to find it.

$entity().state ? 'on' : 'off'

1 Like

Thank you! Exactly the string I was looking for.