We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
https://github.com/twigkit/tempo/blob/master/examples/nested-conditional-templates.html On this example the second list does not show the expected result as it was shown on the first list. I believe that it was caused by
``` if (ready) { var foundTemplates = {}; for (var s = 0; s < children.length; s++) { if (children[s].getAttribute !== undefined) { if (utils.hasAttr(children[s], 'data-template-for') && children[s].getAttribute('data-template-for').length > 0 && this.nestedItem === children[s].getAttribute('data-template-for') && !foundTemplates[this.nestedItem]) { // Nested template this.createTemplate(children[s]); // Guards against recursion when child template has same name! foundTemplates[this.nestedItem] = true; } else if (utils.hasAttr(children[s], 'data-template') && !utils.isNested(children[s])) { // Normal template this.createTemplate(children[s]); } } }
What's the purpose of
// Guards against recursion when child template has same name! foundTemplates[this.nestedItem] = true;
By updating foundTemplates[this.nestedItem] to false the problem seems to be fixed.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
https://github.com/twigkit/tempo/blob/master/examples/nested-conditional-templates.html
On this example the second list does not show the expected result as it was shown on the first list.
I believe that it was caused by
The text was updated successfully, but these errors were encountered: