-
Notifications
You must be signed in to change notification settings - Fork 27.5k
Ng-include inside ng-switch duplicates #3893
Comments
You might want to try 1.2 rc2, which was released yesterday... I believe the issue you have reported is for 1.2 rc1 and has been fixed. Please check with latest. |
@nesteant - can you provide a running example of the problem? |
Could this issue be related to https://groups.google.com/forum/#!topic/angular/IhV_FApq-A4 ? |
Maybe some clues:
But my other ng-include that has a var init OUTSIDE of the ng-view works fine. EDIT |
the problem right now is that we don't abort the compilation and issue an error when two different element transclusion directives with different priorities are applied to the same element (e.g. ng-switch-when + ng-include). We should fix that. @jankuca has tried to address this, but his fix is not good and I'm working on an alternative. |
Issue an error and abort compilation when two directives that ask for transclusion are found on a single element. This configuration is not supported and we previously failed to issue the error because in the case of element transclusion the compilation is re-started and this caused the compilation context to be lost. The ngRepeat directive has been special-cased to bypass this warning because it knows how to handle this scenario internally. This is not an ideal solution to the problem of multiple transclusions per element, we are hoping to have this configuration supported by the compiler in the future. See angular#4357. Closes angular#3893 Closes angular#4217 Closes angular#3307
Issue an error and abort compilation when two directives that ask for transclusion are found on a single element. This configuration is not supported and we previously failed to issue the error because in the case of element transclusion the compilation is re-started and this caused the compilation context to be lost. The ngRepeat directive has been special-cased to bypass this warning because it knows how to handle this scenario internally. This is not an ideal solution to the problem of multiple transclusions per element, we are hoping to have this configuration supported by the compiler in the future. See angular#4357. Closes angular#3893 Closes angular#4217 Closes angular#3307
Issue an error and abort compilation when two directives that ask for transclusion are found on a single element. This configuration is not supported and we previously failed to issue the error because in the case of element transclusion the compilation is re-started and this caused the compilation context to be lost. The ngRepeat directive has been special-cased to bypass this warning because it knows how to handle this scenario internally. This is not an ideal solution to the problem of multiple transclusions per element, we are hoping to have this configuration supported by the compiler in the future. See angular#4357. Closes angular#3893 Closes angular#4217 Closes angular#3307
Issue an error and abort compilation when two directives that ask for transclusion are found on a single element. This configuration is not supported and we previously failed to issue the error because in the case of element transclusion the compilation is re-started and this caused the compilation context to be lost. The ngRepeat directive has been special-cased to bypass this warning because it knows how to handle this scenario internally. This is not an ideal solution to the problem of multiple transclusions per element, we are hoping to have this configuration supported by the compiler in the future. See angular#4357. Closes angular#3893 Closes angular#4217 Closes angular#3307
When ng-include directive is placed inside ng-switch directive it is included each time ng-switch iteration. Reproduced in 1.2 rc1
The text was updated successfully, but these errors were encountered: