mirror of
https://github.com/home-assistant/home-assistant.io.git
synced 2025-07-19 15:26:59 +00:00
Update scripts.markdown: Fix shorthand for templates in loops (#20254)
This commit is contained in:
parent
072a1d67d2
commit
076a69e6aa
@ -429,7 +429,8 @@ For example:
|
|||||||
{% raw %}
|
{% raw %}
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
- while: "{{ is_state('sensor.mode', 'Home') and repeat.index < 10 }}"
|
- repeat:
|
||||||
|
while: "{{ is_state('sensor.mode', 'Home') and repeat.index < 10 }}"
|
||||||
sequence:
|
sequence:
|
||||||
- ...
|
- ...
|
||||||
```
|
```
|
||||||
@ -479,7 +480,8 @@ For example:
|
|||||||
{% raw %}
|
{% raw %}
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
- until: "{{ is_state('device_tracker.iphone', 'home') }}"
|
- repeat:
|
||||||
|
until: "{{ is_state('device_tracker.iphone', 'home') }}"
|
||||||
sequence:
|
sequence:
|
||||||
- ...
|
- ...
|
||||||
```
|
```
|
||||||
|
Loading…
x
Reference in New Issue
Block a user