Skip to content

[FEATURE]: LSP opt-in whitelist mode — replace blacklist with enabled array #33052

Description

@liaosf

Feature hasn't been suggested before.

I have verified this feature hasn't been suggested before.

Current behavior

The current LSP configuration uses an opt-out (blacklist) model:

{
  "lsp": {
    "zls": { "disabled": true },
    "tinymist": { "disabled": true },
    "texlab": { "disabled": true },
    // ... 20+ lines to disable unused LSPs
    "biome": { "disabled": true },
    "astro": { "disabled": true }
  }
}

Problems:

  1. Low transparency — users don't know which LSPs are enabled by default.
  2. Verbose config — must disable 20+ LSPs even if only using 2-3 languages.
  3. Counter-intuitive — listing what you don't want is backwards.

Proposed solution

Introduce an opt-in (whitelist) mode using an enabled array:

{
  "lsp": {
    "enabled": [
      "typescript-language-server",
      "biome",
      "pyright",
      "rust-analyzer"
    ]
  }
}

Benefits:

  1. Simpler config — only list LSPs you use (3-5 entries vs 20+ disabled).
  2. Full transparency — config explicitly shows active LSPs.
  3. Future-proof — new LSPs don't affect you unless added to whitelist.
  4. Resource efficient — no unused LSP processes consuming memory.

The existing disabled blacklist mode should still be supported for backward compatibility. When enabled is present, only listed LSPs start; when absent, current default-all behavior applies.

Additional context

Useful for:

  • Resource-constrained machines
  • Users working with only 1-2 languages
  • CI/headless environments

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions