mirror of
https://github.com/home-assistant/home-assistant.io.git
synced 2025-07-24 01:37:23 +00:00
Update london_air template sensors examples (#20269)
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
This commit is contained in:
parent
fd41a13cfe
commit
4ab31c092f
@ -64,17 +64,14 @@ To explore the data available within the `data` attribute of a sensor use the `d
|
||||
|
||||
```yaml
|
||||
# Example template sensors
|
||||
- platform: template
|
||||
sensors:
|
||||
updated:
|
||||
friendly_name: "Updated"
|
||||
value_template: '{{state_attr('sensor.merton', 'updated')}}'
|
||||
merton_pm10:
|
||||
friendly_name: "Merton PM10"
|
||||
value_template: '{{state_attr('sensor.merton', 'data')[0].pollutants[0].summary}}'
|
||||
westminster_s02:
|
||||
friendly_name: "Westminster S02"
|
||||
value_template: '{{state_attr('sensor.westminster', 'data')[0].pollutants[3].summary}}'
|
||||
template:
|
||||
- sensor:
|
||||
- name: "Updated"
|
||||
state: '{{ state_attr('sensor.merton', 'updated') }}'
|
||||
- name: "Merton PM10"
|
||||
state: '{{ state_attr('sensor.merton', 'data')[0].pollutants[0].summary }}'
|
||||
- name: "Westminster S02"
|
||||
state: '{{ state_attr('sensor.westminster', 'data')[0].pollutants[3].summary }}'
|
||||
```
|
||||
|
||||
{% endraw %}
|
||||
|
Loading…
x
Reference in New Issue
Block a user