mirror of
https://github.com/esphome/esphome-docs.git
synced 2025-04-08 19:05:59 +02:00
Switch the words 'prefix' and 'suffix' (#1551)
I could be wrong, but I think the words 'prefix' and 'suffix' are used in the wrong place. When you append a string, you add text to the end. So the text you add you call a suffix, right? When you prepend a string, you add text to the beginning. So the text you add you call a prefix, right?
This commit is contained in:
parent
57155f384a
commit
0ba5dfdd24
@ -62,8 +62,8 @@ Filters are processed in the order they are defined in your configuration.
|
||||
filters:
|
||||
- to_upper:
|
||||
- to_lower:
|
||||
- append: "_prefix"
|
||||
- prepend: "suffix_"
|
||||
- append: "_suffix"
|
||||
- prepend: "prefix_"
|
||||
- substitute:
|
||||
- "suf -> foo"
|
||||
- "pre -> bar"
|
||||
@ -106,7 +106,7 @@ Adds a string to the end of the current string.
|
||||
- platform: template
|
||||
# ...
|
||||
filters:
|
||||
- append: "_prefix"
|
||||
- append: "_suffix"
|
||||
|
||||
``prepend``
|
||||
***********
|
||||
@ -119,7 +119,7 @@ Adds a string to the start of the current string.
|
||||
- platform: template
|
||||
# ...
|
||||
filters:
|
||||
- prepend: "suffix_"
|
||||
- prepend: "prefix_"
|
||||
|
||||
``substitute``
|
||||
**************
|
||||
|
Loading…
Reference in New Issue
Block a user