Variable does not get formatted properly in a .pug-file
Answered
When i write an unbuffered code, pStorm does not recognize that it is a JS context and thus does not indent it properly
In the following two figures(which thankfully work both) illustrating what i mean:
What i want

What pStorm does

pStorm version: 2016.2.2
pug plugin version: 162.1024.2
How can i fix this problem?
Please sign in to leave a comment.
Try the same in latest EAP. It looks as desired there.
awesome! thanks Dimitry
You're welcome! Next IDE version would include this.
After the update (pStorm & Pug plugin) the problem persists.
Also what i've noticed is that the the .pug files in the sidebar do not have an icon anymore.
pStorm version: 2016.3
pug plugin version: 163.6957.3
Hello, Dmitry Tronin! Two years have passed, but this problem still exists((( Can you explane this and maybe give me some advice???
Please describe the issue you're facing in details & attach a code sample if needed.
You have the 3 years old the same issue in youtrack (https://youtrack.jetbrains.com/issue/WEB-21974) and ask me describe my issue for creating another one. What the crap is going on? You ignored massage by Morten Sassi created November 24, 2016 21:43 and checked this post answered. Jetbrains' support for 3 years messing about mentioned issue in youtrack. Why??
Yes, unfortunately we missed the reply on November 2016.
The post was marked answered long ago because the problem was fixed in one of the EAP builds.
I've asked you to describe the problem in order to identify which one of two you're facing: wrong indentation or missing icons.
Thanks for providing the link to a YouTrack report: I would suggest checking for an update with a corresponding developer there. I'm not a developer and unfortunately can't advise when the issue will be fixed.
Thank you for more detailed answer. You can't advise when the issue will be fixed, but you can to speed up problem solving. I think so... Can you increase priority of mentioned issue? Maybe we make Dennis Ushakov pay attention to this problem
An can you tell me which one of the EAP builds contain solve this issue?
I think Dmitry got it wrong when he said the issue has been fixed somewhere in the past, probably relying on his own first (erroneous) comment in this thread.
This bug is coming from WebStorm (it's they who develop the Pug plugin), and unfortunately it's not up to us (PhpStorm team members) to manage priorities there.
I can see that you have already left a comment there, I hope Dennis will reply soon.
Thanks. I hope as well