I’m running across a scenario trying to access an array index, and something does not work as I need to.
I am wondering if someone can check my code and see what the problem is
TYA
{% set test_var = ['00','01','11','10'] %}
{{states('counter.aly_bed_swtich_count')}} / this outputs 1 correctly
{{test_var[2]}} //this outputs 11 correctly
{{test_var[states('counter.aly_bed_swtich_count')]}} // this outputs nothing, vs expected 01
2 posts - 2 participants