Skip to content

☂️ Formatter: Support formatting of embedded code #8237

Open
@MichaReiser

Description

@MichaReiser

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:

Metadata

Metadata

Assignees

No one assigned

    Labels

    formatterRelated to the formatterwishNot on the current roadmap; maybe in the future

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions