Open Brick85 opened 8 months ago
Hi! @JoosepAlviste, any reason for not accepting this MR? I've just tested it and it seems to work. It's very important for Django templates.
Hey! To be honest, I have kind of forgotten about this PR 😅 Thanks for the ping!
I can definitely see that we should handle the Django templates correctly. At first glance, it seemed like having a not_nested_languages
solution was a bit too specific (only required for 1 filetype), so I was hoping that I could come up with a better approach.
If I understand it correctly, then we want to absolutely ignore any html
nodes inside htmldjango
files? So, we would always use the htmldjango
commenting style ({# %s #}
) in the whole file. It would be nice, though, if <script>
tags still had the correct commentstring
.
To be honest, I have kind of forgotten about this PR 😅 Thanks for the ping!
It happens. :stuck_out_tongue_closed_eyes:
It would be nice, though, if Githubissues.
Githubissues is a development platform for aggregating issues.
This pull request introduces support for comments in the HTMLDjango template language. While the detection of nested languages and formatting comments accordingly is generally advantageous, there are cases where it may be counterproductive, especially in file types like HTMLDjango templates.
In HTMLDjango templates, it is preferable to utilize Django template comments not only within HTML but also in JavaScript and CSS. These comments effectively exclude code from rendering and prove beneficial. The proposed change becomes essential for commenting on template control statements, addressing a limitation in the existing functionality.
Please review and consider merging this pull request to enhance the plugin's compatibility with HTMLDjango templates.