-
Notifications
You must be signed in to change notification settings - Fork 35.7k
Closed
Labels
bugIssue identified by VS Code Team member as probable bugIssue identified by VS Code Team member as probable bugeditor-autoindentEditor auto indentation issuesEditor auto indentation issuesinsiders-releasedPatch has been released in VS Code InsidersPatch has been released in VS Code InsidersjavascriptJavaScript support issuesJavaScript support issuestypescriptTypescript support issuesTypescript support issuesverifiedVerification succeededVerification succeeded
Milestone
Description
Does this issue occur when all extensions are disabled?: Yes
- VS Code Version: 1.88.0
- OS Version: Ubuntu 22.04
Steps to Reproduce:
if (true)<enter>
{<enter>
}This seems to happen on for and while as well. In other languages auto-indentation doesn't happen after the first <enter> in the example. While it could be good as a feature, it would be great if on typing the opening bracket, it would automatically un-indent. Also, it seems like the kind of thing that needs a toggle, because it can backfire in multiple ways.
Another thing that I noticed was that the auto-indentation happens even if the if line is commented out.
// if (true)<enter>
|<cursor ends up here>This was not a problem in the previous version.
AndrewStovell, TheWyo, Jemt, FlowIT-JIT, ssigwart and 4 more
Metadata
Metadata
Assignees
Labels
bugIssue identified by VS Code Team member as probable bugIssue identified by VS Code Team member as probable bugeditor-autoindentEditor auto indentation issuesEditor auto indentation issuesinsiders-releasedPatch has been released in VS Code InsidersPatch has been released in VS Code InsidersjavascriptJavaScript support issuesJavaScript support issuestypescriptTypescript support issuesTypescript support issuesverifiedVerification succeededVerification succeeded