-
Notifications
You must be signed in to change notification settings - Fork 27.4k
directive behavior differs from 1.2.26 to 1.3.4 #10236
Comments
Yes, I believe that this one of a breaking changes in 1.3.x, trying to find the relevant commit |
It seems a big change for me but I don't find any mention of it in https://docs.angularjs.org/guide/migration |
An isolated scope mustn't be accessible from outside, so I think it's a bug fix. |
I don't think this is going to be rolled back, I'm in agreement with @thorn0 --- but lets make sure that the change is documented |
From a bisect, looks like 2ee29c5 is responsible. @petebacondarwin could you document this in the changelog? |
@thorn0 is correct here. In 1.2.x this was a bug that the isolated scope was leaking into the attributes of the template that contained the isolated scope directive. It was never supposed to leak - it was not deemed a breaking change but a fix. But since some people may have been erroneously relying on this bug then we probably should add a note in the CHANGELOG and migration docs. |
I'm trying to understand if this is what forces me to wrap the directive template with an extra tag if I want to use ng-if? ng-show seems to work though. http://plnkr.co/edit/nVsNbyzE8ZigiMxyjzZG?p=preview |
@matiaslarsson - Possibly it is due to this bug: #9837 |
http://plnkr.co/edit/giVsWj1HDjlVN8lEJaHR?p=preview
In 1.2.26
test-directive ng-hide="directiveScope" does the job to hide
in 1.3.4 must be
test-directive ng-hide="controllerScope"
I think 1.3.4 behavior is the correct one, but is it really so?
Is this a wanted breaking change?
Fred
The text was updated successfully, but these errors were encountered: