Closed ishan1608 closed 10 years ago
This behavior is intended and common around code editors. When you fold code that is executed under a certain condition it seems very practical to see the condition. You fold the code according to its logic... Same goes for the variables, the name isn't folded, just the values.
The folding logic for .js files works by finding ranges of the contents within braces. Hence it has a lot to do with the format of the code.
I am closing this issue.
When folding the code, the arrow is positioned in wrong location, and thus does not folds the entire code, it leaves some code at the top. I believe this may be occurring because the extension must be folding from the line where opening brace ' { ' is placed and not from where the code actually starts.
To reproduce go to brackets>src>editor>ImageViewer.js:265 click on the code folding icon or use the shortcut to fold the ' if ' statement. Screenshots :