Skip to content

Commit ebaf8c8

Browse files
committed
fix: Indent after pressing enter on a blank line
1 parent 924d277 commit ebaf8c8

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

editors/code/src/config.ts

+2-1
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,8 @@ export class Config {
9999
let onEnterRules: vscode.OnEnterRule[] = [
100100
{
101101
// Carry indentation from the previous line
102-
beforeText: /^\s*$/,
102+
// if it's only whitespace
103+
beforeText: /^\s+$/,
103104
action: { indentAction: vscode.IndentAction.None },
104105
},
105106
{

0 commit comments

Comments
 (0)