Skip to content
This repository has been archived by the owner on Apr 12, 2024. It is now read-only.

ng:include and ng:repeat do not like each other #206

Closed
mhevery opened this issue Jan 4, 2011 · 2 comments
Closed

ng:include and ng:repeat do not like each other #206

mhevery opened this issue Jan 4, 2011 · 2 comments

Comments

@mhevery
Copy link
Contributor

mhevery commented Jan 4, 2011

The issue is with this code in ng:include

if (element[0]['ng:compiled']) {
this.descend(true);
this.directives(true);
} else {
element[0]['ng:compiled'] = true;

The problem is that this
element[0]['ng:compiled'] = true;
sets a flag on instance of element not on the dom. As a result the flag does not get copied when the loop gets unrolled in the ng:repeat and the code gets double compiled

@rdkhatch
Copy link

Hi Misko,

We are encountering this bug with 0.9.19. ng:include never gets compiled.

Are there any updates for this? Is this fixed in 0.10?

Please let us know. Thank you very much!

Ryan [and Jeremiah]

@mhevery
Copy link
Contributor Author

mhevery commented Jan 17, 2012

0.10.17 will have a new compiler which is mostly done here: https://github.com/mhevery/angular.js/tree/directive It should not have this issue.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants