I’m using the a template (found somewhere online but can’t give credit as I can’t remember where…so apologies to the creator) in a markdown card but in the resulting list it’s creating a blank row below each entity.
I don’t know enough about templates to identify if any part of the code is creating the spacing so I was hoping someone could please help?
Below is the template, the resulting list and an example of how I would expect to see it taken from another markdown card template I have:
Template
{% set device_ids = states
| selectattr('state', 'in', ['unavailable', 'unknown'])
| map(attribute='entity_id')
| map("device_id")
| map("string")
| unique
| select("ne", "None")
| list
%}
{% for device_id in device_ids %}
{{ device_attr(device_id, "name_by_user") or device_attr(device_id, "name") }}
{% endfor %}
Result
Example of expected result