I’ve been using categories to categorize my scenes. I’m writing a template to filter some scenes by area and category but I can’t seem to find a way to filter by category. For example, for labels it’s possible to use label_entities()Templating - labels, is there an equivalent for listing entities for a category?
Or the alternative is to rely on labels for this (for the time being)?
Categories is purely a UI thing as I understand it. Not sure why yet another thing was introduced instead of making is easy to group/filter by labels instead.
if you can avoid expand you should. This is because expand resolves everything in the list that is supplied to it, where as other methods only resolve the ending result. In layman terms, expand is slower and not optimized.
Kinda-sorta related: Is there some way to detect whether an entity is a group without simply expanding it and see what comes out?
Looking at for example a light group in developer tools there is no literal group attribute at least. While it does have an entity_id attribute listing the lights in the group, other entities (scenes for example) may for sure have such an attribute without being a group so that isn’t really foolproof.