Open
Description
Support formatting Python code embedded in other languages like:
- Markdown
- reStructuredText
- HTML
- ...
The goal of this issue is not that we implement support for all these languages but to build up the infrastructure to run ruff (at least the formatter) on files that contain embedded python code and format it. Ideally, the infrastructure would, in the future, allow us to support arbitrary nesting:
- Format SQL in Python
- Format Markdown in Python
- ...
Prettier and JetBrains code formatter do an excellent job at this.
Related: