I have places in my code where I have this:
I would like to be able to use it like
had created above custom directive for one of my use case.
JSON.parse is used to parse string "true" returned from html to boolean true in JS.
another way to use attrs.focus === "true" for if condition.