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
switch tab: "case" align with "switch" #179
Comments
@damienleroux which version of I just tested with Input: function execute(test) {
switch (test) {
case a:
break;
}
}
switch (test) {
case a:
break;
} Formatted: function execute(test) {
switch (test) {
case a:
break;
}
}
switch (test) {
case a:
break;
} |
I tested it in another Sublime Text: same problem... |
Ok, it might be an issue with the Sublime plugin since this does not appear to be an issue with the latest version of Also, is everything else getting formatted just fine? It is just |
I reproduce the case on a sublime text 3 64 bit ( portable version) on Window 7 64 installed from scratch.
There is no mention of a particular version of sublime-jsfmt. I have a similar probleme formatting with this code: function test() {
var mytest;
}
module.exports = function test() {
var mytest;
} This code is formatted like this: function test() {
var mytest;
}
module.exports = function test() {
var mytest;
} It seems the statement "module.exports = " breaks tabulation inside the function. |
Hmm, this might be an issue with I have opened mihai-vlc/sublime-jsfmt#37 as I believe this might be an issue with |
Also, I am sorry that you are having difficulties, hopefully we can help get them resolved. |
Thank you very much for helping :). It gives me hope |
@damienleroux have you had any luck here? |
Yes, As explained by from sublime jsfmt support, adding "TopLevelFunctionBlock" resolved my problem. Thank you for your help! |
Great, glad you were able to resolve the problem! |
Hi,
I note that switch statement use wrong tabulation:
It should be:
Let me know if I miss configuration possibilities or if you can enhance jsfmt with this?
Thank you!
The text was updated successfully, but these errors were encountered: