-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
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
Nunjucks / Jinja / Django {% templates %} correct support? #1110
Comments
#1104 might address your issue. Try it locally. |
I'm using js-beautify via Visual Studio Code extension https://github.com/lonefy/vscode-js-css-html-formatter. So I've updated the source in C:\Users\username.vscode\extensions\lonefy.vscode-JS-CSS-HTML-formatter-0.2.2\node_modules\js-beautify\ to the one downloaded from GitHub. No any changes, it still removes linebreak between two template tags. |
Any progress on this? Tried with vscode as of today (26.09.2017) and the problem still exists If you need more info/debug let me know. |
No progress. This needs someone to implement it. |
I have same problem |
I'm desperate! I've tried everything, I've tried things for Jinja2 and Twig but nothing. I don't know what to do... |
@bitwiseman any hints on how to implement something like this? |
@koshkin-kna - no, sorry. The project your referred to is 4 years out of date from the current version of beautifier. |
I am having this issue as well... :( |
I just tried this code in v1.8.6 and it appears to no longer be an issue. @softshape do you want to double-check and let me know what you find? It does remove the indentation, but as that was not the issue with the original filed bug, I think it might be resolved. |
I am getting a linebreak after a {% in my django templates. |
@dancaron What input are you providing? What version are you using? |
Input:
Output:
Version: js-beautify 1.8.8 (vscode) However: I noticed that if I use "format selection" the output does not include a line-break, and works as expected. If I use "format document" you will see the output as above. |
@dancaron Try this on https://beautifier.io (v1.9.0-beta 3). It should be fixed now. |
Right now the code like:
losts its linebreaks between template tags after formatting:
Any way to avoid that? This affects all {% %}, {# #}, and {{ }} tags.
The text was updated successfully, but these errors were encountered: