Document short hand templates in condition actions (#20794)

This commit is contained in:
Erik Montnemery 2021-12-21 12:29:48 +01:00 committed by GitHub
parent 45071ecdc0
commit 65ef7786dd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -424,7 +424,7 @@ condition:
{% endraw %} {% endraw %}
But also in the `repeat` action's `while` or `until` option, or in a `choose` action's `conditions` option: It's also supported in the `repeat` action's `while` or `until` option, or in a `choose` action's `conditions` option:
{% raw %} {% raw %}
@ -447,15 +447,15 @@ But also in the `repeat` action's `while` or `until` option, or in a `choose` ac
{% endraw %} {% endraw %}
<div class="note warning"> It's also supported in script or automation `condition` actions:
While conditions can be used in script sequences or automation actions, the {% raw %}
shorthand for template conditions cannot be used directly in those constructs.
However, if an used action supports conditions itself, like `choose` and ```yaml
`repeat`, the shorthand template conditions will be accepted in those cases. - condition: "{{ is_state('device_tracker.iphone', 'away') }}"
```
</div> {% endraw %}
[template]: /topics/templating/ [template]: /topics/templating/
[automation-templating]: /getting-started/automation-templating/ [automation-templating]: /getting-started/automation-templating/