Skip to content

Formatter configuration? #848

Description

@KonerDev

I was looking into how formatters are currently integrated in the library and I’m wondering what the intended design here is.

  1. Right now the formatter seems effectively tied to the language instance (Language.formatter / LspLanguage.setFormatter). When using language servers the normal language formatter gets overridden by the LSP connection logic (LspFormatter). This makes it difficult to reliably provide a custom formatter.

  2. There also doesn’t seem to be a clear API for swapping formatters at runtime (no dedicated setter).

What was the original idea for how formatter selection and override should work here?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions