Add config for Helix editor (#1200)

pull/1199/head
Marek S. Łukasiewicz 2025-01-04 06:59:12 +01:00 committed by GitHub
parent df9edc5d64
commit e94c4843b4
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 43 additions and 0 deletions

43
.helix/languages.toml Normal file
View File

@ -0,0 +1,43 @@
# This file configures the Helix editor to use Deno for language support,
# instead of user defaults for JavaScript and TypeScript. Reproduced from:
# https://github.com/helix-editor/helix/wiki/Language-Server-Configurations#deno
[[language]]
name = "javascript"
shebangs = ["deno"]
roots = ["deno.json", "deno.jsonc"]
file-types = ["js"]
language-servers = ["deno-lsp"]
auto-format = true
[[language]]
name = "typescript"
shebangs = ["deno"]
roots = ["deno.json", "deno.jsonc"]
file-types = ["ts"]
language-servers = ["deno-lsp"]
auto-format = true
[[language]]
name = "jsx"
shebangs = ["deno"]
roots = ["deno.json", "deno.jsonc"]
file-types = ["jsx"]
language-servers = ["deno-lsp"]
auto-format = true
[[language]]
name = "tsx"
shebangs = ["deno"]
roots = ["deno.json", "deno.jsonc"]
file-types = ["tsx"]
language-servers = ["deno-lsp"]
auto-format = true
[language-server.deno-lsp]
command = "deno"
args = ["lsp"]
environment = { NO_COLOR = "1" }
[language-server.deno-lsp.config.deno]
enable = true
suggest = { completeFunctionCalls = false, imports = { hosts = { "https://deno.land" = true } } }