Home Dynamically hide/unhide an entire view in Home Assistant
Post
Cancel

Dynamically hide/unhide an entire view in Home Assistant

The States UI is now deprecated and will be completely removed from Home Assistant in version 0.107.0. Therefore, this won’t work anymore after that.

Reddit user /u/lordjustice17 sent me a message (see below) with a different use of Dynamically hide/unhide an entire view in Home Assistant.



His code:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
- platform: template
 switches:
   console:
     friendly_name: Control Panel
     value_template: "{{ is_state_attr('group.console', 'view', true) }}"
     turn_on:
       service: group.set
       data:
         object_id: console
         view: true
     turn_off:
       service: group.set
       data:
         object_id: console
         view: false


This creates a switch that shows and hides a view called console. Clever!

This post is licensed under CC BY 4.0 by the author.

Use an IP phone to 'say' Home Assistant notifications

Track battery levels with Home Assistant and Custom UI

Comments powered by Disqus.