Skip to content

feature request: lsp fallback never while using injected formatter #791

@KevinNitroG

Description

@KevinNitroG

Did you check existing requests?

  • I have searched the existing issues

Describe the feature

Could we have an option to disable lsp fallback while using the injected formatter

Provide background

I'm using injected formatter in writing markdown with some code blocks that contain programming language. I think I'm different from other people in the issue related (#409, #200), which spawns LSP running in the background, is annoying and resource-consuming (for me).

What is the significance of this feature?

nice to have

Additional details

I have tried so far, but still couldn't achieve what I want

opts = {
  default_format_opts = {
    lsp_format = "fallback",
  },
  formatters = { -- and other formatters setup that I don't list here
    injected = {
      options = {
        lang_to_formatters = {
          json = is_executable("jq") and { "jq" } or nil,
        },
      },
      lsp_format = "never",
    },
  },
},

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions