Add it in Tori
- Open Settings with the gear in the title bar.
- Go to LSP.
- TypeScript / JavaScript is already there: it ships inside Tori. When the catalog has a newer version, Add a language lists it with Update.
Adding writes one file and runs nothing. The server itself already ships inside Tori.
Use it without the catalog
Download the file and drop it in the folder below. Tori loads it the next time it starts.
Download file typescript.toml
~/.config/tori/packs/lsp/
The file
typescript.tomlRead only
1# Bundled TypeScript/JavaScript server. Tori ships this one (see2# `pnpm lsp:install`), so it is the only config using the `bundled_node`3# launch kind. See LSP-SERVERS.md for the schema.45schema_version = 16id = "typescript"7label = "TypeScript / JavaScript"8description = "TypeScript and JavaScript, through typescript-language-server"9license = "Apache-2.0"10contributor = { name = "Tori", github = "gettori" }11verified_against = "typescript-language-server 4.4.1"12verified_on = "2026-10-09"1314# `tsconfig.json`/`jsconfig.json` first so a package inside a monorepo gets a15# server rooted at its own compiler config rather than at the repo root.16root_markers = ["tsconfig.json", "jsconfig.json", "package.json", ".git"]1718# tsserver answers from a warm project quickly, but a cold first `initialize`19# on a large repo can take a few seconds. The library's own default is 3s,20# which is too tight for the first request after a project opens.21request_timeout_ms = 200002223# The server prefers the workspace's own `node_modules/typescript` to the24# bundled one and loads tsconfig `plugins`, so opening a file runs project code.25runs_project_code = true2627[languages]28ts = "typescript"29mts = "typescript"30cts = "typescript"31tsx = "typescriptreact"32js = "javascript"33mjs = "javascript"34cjs = "javascript"35jsx = "javascriptreact"3637[launch]38kind = "bundled_node"39entry = "resources/lsp/node_modules/typescript-language-server/lib/cli.mjs"40args = ["--stdio"]4142# Code lens, off in the server until it is told otherwise (wave 7, #68).43#44# Without this table `textDocument/codeLens` answers an empty array: the server45# advertises `codeLensProvider` unconditionally, but both providers check the46# *workspace configuration* before producing anything (`cli.mjs:21364`), and a47# preference nobody sent reads as off. Verified both ways against the bundled48# 4.4.1: no table, 0 lenses; this table, 3 lenses on a file with three exported49# symbols. So Tori's own `codeLens` setting would have drawn nothing for50# TypeScript without it.51#52# Read out of the *workspace* configuration and not out of53# `initialization_options`, which is what it looks like it should be: the54# provider calls `getWorkspacePreferencesForFile` (`cli.mjs:21129`), which55# indexes this table by `typescript`/`javascript`, so the mechanism that works56# is the one used here. (`initialization_options` reached no primary server at57# all until the `lsp-client` 6.3.0 bump, which is the other reason.)58#59# Enabling it here costs nothing while Tori's setting is off, because the60# expense is in the request and Tori does not make one: `provideCodeLenses`61# runs per request, and the reference counting is in `codeLens/resolve`.62#63# `showOnAllFunctions` is deliberately not set. On it, every inner helper gets a64# lens, most of them reading "0 references"; the default keeps them to exported65# and class members, which is what the counts are worth reading for.66[settings.typescript.referencesCodeLens]67enabled = true6869[settings.typescript.implementationsCodeLens]70enabled = true7172[settings.javascript.referencesCodeLens]73enabled = true7475[settings.javascript.implementationsCodeLens]76enabled = true