-
Notifications
You must be signed in to change notification settings - Fork 279
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bo-switch-when does not work, when value is a string #87
Comments
My quick solution just now was using
|
Hi @tylkomat
|
Indeed, but not if that string is a url. My solution has also the advantage, that you can compare to another scope value. I think it also makes sense to use BTW the example in the readme also uses quotes, at least one ^^ |
I know what you mean but I'm trying to keep the bo-* directives as close as possible to the ng-* directive so people can use them as drop-in replacement for angular standard directives. The change you suggest would break the compatibility with ng-switch. Thank you for noticing the readme, I'll change it straight away. |
Ok I understand, but still it does not work, when the String you compare to is a URL. See this example: http://plnkr.co/edit/p7yuQivWk5RuLhwPRw3e?p=preview |
This is indeed a bug, scope.$eval cannot parse special characters like : or /
and in the controller:
|
Great, Thanks. |
Bo-switch-when does not select the correct value, when comparing with a string. Here is an example:
http://plnkr.co/edit/FUrCzW9sTuLtYOAFgCqc?p=preview
The text was updated successfully, but these errors were encountered: