You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on May 29, 2019. It is now read-only.
With v0.10.0 (via bower) I am trying to obtain a tab's active state from an expression, such as <tab active="{{foo() == bar}}">...</tab>", however it breaks with 'undefined is not a function'
It seems that a simply wrapping the setActive call with an if statement does the trick:
getActive = $parse(attrs.active);
setActive = getActive.assign;
//...
scope.$watch('active', function(active) {
// Note this watcher also initializes and assigns scope.active to the
// attrs.active expression.
if(setActive) { // <--- Add this
setActive(scope.$parent, active); // <-- This breaks because an expression's value can't be set
} // <--- Add this
The text was updated successfully, but these errors were encountered:
With v0.10.0 (via bower) I am trying to obtain a tab's active state from an expression, such as
<tab active="{{foo() == bar}}">...</tab>"
, however it breaks with 'undefined is not a function'It seems that a simply wrapping the
setActive
call with an if statement does the trick:The text was updated successfully, but these errors were encountered: