microsoft / microsoft/vscode-black-formatter

Support for format on type

Open
#489 6 comments 0 reactions 2 assignees View on GitHub

@karthiknadig is already working on this.

Since Mar 20, 2024.

feature-request
Dominant language
Python
Stars
196
Forks
49
Avg merge
1d 5h
Merged PRs (30d)
7

Description

I hope this message finds you well. I am writing to express a feature request for the Python extension that I believe would significantly enhance the coding experience for users like myself.

Currently, I find myself frequently formatting my code using the Ctrl+Shift+I shortcut, which, although effective, interrupts the flow of coding and feels somewhat cumbersome. Drawing inspiration from features available in Visual Studio, I would like to propose the implementation of automatic code formatting upon pressing the Enter key.

The functionality I envision is straightforward: when a user presses Enter to move to a new line, the Python extension would automatically format the preceding line of code according to the defined style guidelines or user preferences.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.