Add bool() filter to Esphome Jinja template engine #3479
Unanswered
larrybarello
asked this question in
Core functionality
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Describe your core improvement
I use key/value in the command line to configure my top level yaml. It would be convenient to have "esphome -s somekey true/false compile some.yaml" There are a lot of filters implemented but bool seems absent.:
Of course, this can be simulated by using text only, but it could be confusing since the command line always passes text but internally the variable could be "bool" e.g. the following always evaluates to true regardless of the string being passed in.
This should work, but I admit to not having tried it.
Beta Was this translation helpful? Give feedback.
All reactions