Skip to content

Format cell on run like the nb_black extension does. #7058

Closed
microsoft/vscode
#182924
@nickeubank

Description

@nickeubank

One of my favorite features of vscode (and other good editors) is format on save. Obviously that's not feasible for notebooks because they aren't linear and so a formatter would struggle if it tried to parse everything every time the notebook was saved. But there is a solution that's like format on save for notebooks: format on run.

Now that notebook cells can be formatted, would it be possible to create a setting where each cell is formatted when it's run? It's already available in regular jupyter notebooks thanks to nb_black, and I'd love to see it in VS code notebooks.

Metadata

Metadata

Assignees

Labels

feature-requestRequest for new features or functionalitynotebook-workflowIssues that interrupt expected or desirable behavioron-testplan

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions