Skip to content

Commit

Permalink
chore: fix formatter
Browse files Browse the repository at this point in the history
  • Loading branch information
lajbel committed Oct 24, 2024
1 parent 9bd19bb commit 0ae7758
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/actions/format.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,7 @@ export const format = () => {
indent_char: " ",
});

const oldPos = $editorInstance.get()?.getPosition();
$editorInstance.get()?.setValue(formattedCode);
$editorInstance.get()?.setPosition(oldPos!);
};

0 comments on commit 0ae7758

Please sign in to comment.