mirror of
https://github.com/home-assistant/home-assistant.io.git
synced 2025-07-22 08:46:51 +00:00
Clarified the behavior of conditions. (#10461)
* Clarified the behavior of conditions. The current reading of the documentation indicates that if a condition evaluates to true it stops executing. Added additional context to the first line to describe the actual behavior. * Updated docs to clarify conditions behavior The current reading of the documentation indicates that if a condition evaluates to true it stops executing. Added additional context to the first line to describe the actual behavior. * Renamed script to automation * Changed to script or automation for consistency.
This commit is contained in:
parent
54dceafee8
commit
0daad58567
@ -4,7 +4,7 @@ description: "Automations can test conditions when invoked."
|
||||
redirect_from: /getting-started/automation-condition/
|
||||
---
|
||||
|
||||
Conditions are an optional part of an automation rule and can be used to prevent an action from happening when triggered. Conditions look very similar to triggers but are very different. A trigger will look at events happening in the system while a condition only looks at how the system looks right now. A trigger can observe that a switch is being turned on. A condition can only see if a switch is currently on or off.
|
||||
Conditions are an optional part of an automation rule and can be used to prevent an action from happening when triggered. When a condition does not return true, the automation will stop executing. Conditions look very similar to triggers but are very different. A trigger will look at events happening in the system while a condition only looks at how the system looks right now. A trigger can observe that a switch is being turned on. A condition can only see if a switch is currently on or off.
|
||||
|
||||
The available conditions for an automation are the same as for the script syntax so see that page for a [full list of available conditions](/docs/scripts/conditions/).
|
||||
|
||||
|
@ -4,7 +4,7 @@ description: "Documentation about all available conditions."
|
||||
redirect_from: /getting-started/scripts-conditions/
|
||||
---
|
||||
|
||||
Conditions can be used within a script or automation to prevent further execution. A condition will look at the system right now. For example a condition can test if a switch is currently turned on or off.
|
||||
Conditions can be used within a script or automation to prevent further execution. When a condition does not return true, the script or automation will stop executing. A condition will look at the system right now. For example a condition can test if a switch is currently turned on or off.
|
||||
|
||||
Unlike a trigger, which is always `or`, conditions are `and` by default - all conditions have to be true.
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user