Update yaml.markdown (#13049)

* Update yaml.markdown

Added warning about booleans

* Update source/_docs/configuration/yaml.markdown

Co-Authored-By: Franck Nijhof <frenck@frenck.nl>

* ✏️ Tweak

Co-authored-by: Franck Nijhof <frenck@frenck.nl>
This commit is contained in:
jonwaland 2020-04-19 21:25:43 +10:00 committed by GitHub
parent 99b6370dc8
commit c6dae1b1d2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -111,3 +111,13 @@ This means that you've mistakenly entered a tab character, instead of spaces.
Home Assistant is case sensitive, a state of `'on'` is not the same as `'On'` or `'ON'`. Similarly an entity of `group.Doors` is not the same as `group.doors`.
If you're having trouble, check the case that Home Assistant is reporting in the dev-state menu, under *Developer tools*.
### Booleans
YAML treats `Y`, `true`, `Yes`, `ON` all as `true` and `n`, `FALSE`, `No`, `off` as `false`. This means that if you want to set the state of an entity to `on` you *must* quote it as `'on'` otherwise it will be translated as setting the state to true. The same applies to `off`.
Not quoting the value may generate an error such as:
```txt
not a valid value for dictionary value @ data
```