Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP


Support Nested Blocks #64

DrMartiner opened this Issue · 16 comments

Swig currently throws an error when attempting to nest blocks.

{% block foo %}
   {% block bar %}
   {% endblock %}
{% endblock %}

This is a powerful feature that it should support.


swig currently doesn't have the ability to do nested blocks. A major rewrite of the compiled output is necessary before this can happen.

I've re-worded this issue slightly.



I would love to see this, blocks aren't that usable if you can't nest them.




Thanks for the support everyone. I've already begun work on this. Please understand that saying +1 doesn't give me more time in my day :) Although... I do wish it did...


Thanks for your work, looking forward to see this implemented :)


+time OR time++ ?
+1 for now ;)


time++ is frowned upon. How about time += 1


This would indeed be very useful :)


any news?


Sorry everyone, busy with work, moving, and life. I haven't had time to prioritize open source work lately.

@jbergstroem jbergstroem referenced this issue in mozilla/nunjucks

Different between swig #83


We are happy over here with nunjucks that supports this, and much more :)


jlongster, had I found about your project from other sources, I would probably look into it and even migrate. On the other hand, you decided to promote yourself on another project's page and I just consider that to be bad taste.

paularmstrong, I understand that work+life and all makes OSS development become a p2 thing. I hope you manage to find some extra time (or that someone with more time than you and I does). Keep up the good work and thanks for the project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.