---
title: "How We Made the Deno Language Server Ten Times Faster"
description: "Deno cut language server auto-completion latency in large codebases from about 8 seconds to under one second by fixing how its Rust server synchronizes project state with the embedded TypeScript compiler (tsc)."
url: "https://swe.quest/articles/how-we-made-the-deno-language-server-ten-times-faster-b61c253ad0b180d5"
canonical: "https://deno.com/blog/optimizing-our-lsp"
source: "Deno"
published: "2024-06-20"
difficulty: "medium"
kind: "Case study"
reading_minutes: 7
tags: ["performance","developer-tools","typescript","caching","rust"]
---

# How We Made the Deno Language Server Ten Times Faster

A post on [Deno](https://swe.quest/sources/deno.md), published 2024-06-20, 7 min read, Case study. Original: [https://deno.com/blog/optimizing-our-lsp](https://deno.com/blog/optimizing-our-lsp)

## Summary

Deno cut language server auto-completion latency in large codebases from about 8 seconds to under one second by fixing how its Rust server synchronizes project state with the embedded TypeScript compiler (tsc). Flamegraphs from a customer-modeled benchmark (75k lines of app code, 750k in dependencies) showed tsc spending most of its time pulling every file's contents across the expensive Rust-to-JavaScript boundary on each request. The fixes were to sync only local files, since remote npm:/jsr:/URL dependencies are cached and rarely change, and to add a JavaScript-side cache that the Rust server invalidates on file changes, which eliminated most cross-boundary calls. The improvements shipped in Deno 1.43.

Written by swe.quest, not by the author.

**Difficulty:** Medium: assumes a working developer; shows how it is built or done

## Topics

- [Performance engineering](https://swe.quest/tags/performance.md) (Reliability & operations)
- [Developer tools](https://swe.quest/tags/developer-tools.md) (Engineering practices)
- [TypeScript](https://swe.quest/tags/typescript.md) (Languages)
- [Caching](https://swe.quest/tags/caching.md) (Backend & APIs)
- [Rust](https://swe.quest/tags/rust.md) (Languages)

## Prerequisites

- Language Server Protocol basics
- TypeScript compiler ([easy posts on TypeScript](https://swe.quest/tags/typescript.md?difficulty=easy))
- flamegraphs

## Keywords

Deno, Language Server Protocol, tsc, Jaeger, Chrome DevTools, Deno 1.43

## Related posts

- [Deno 1.43: Improved Language Server performance](https://swe.quest/articles/deno-1-43-improved-language-server-performance-ce41f07ca52bb667.md): Deno · 2024-05-01 · Medium · 9 min read · JavaScript, TypeScript, Runtimes & VMs, Developer tools
  Deno 1.43 cuts Language Server auto-completion latency in large codebases from 6-8 seconds to under one second and sharply reduces LSP memory use, fixing out-of-memory failures.
- [Deno 1.42: Better dependency management with JSR](https://swe.quest/articles/deno-1-42-better-dependency-management-with-jsr-c869439ba578c752.md): Deno · 2024-03-28 · Medium · 9 min read · JavaScript, TypeScript, Runtimes & VMs, Build systems, Developer tools
  Deno 1.42 adds first-class JSR support through new \`deno publish\` and \`deno add\` subcommands, which install packages from JSR and npm and write import map entries.
- [Deno 2.9](https://swe.quest/articles/deno-2-9-919531dc50e2e28a.md): Deno · 2026-06-25 · Medium · 24 min read · JavaScript, Runtimes & VMs, Build systems, Performance engineering, Developer tools
  Deno 2.9 introduces experimental \`deno desktop\`, which compiles a web UI plus Deno logic into a single native binary using either the OS webview or bundled Chromium via CEF, with native window, tray and dock APIs and cross-compilation to installers for all five targets. \`deno install\` now seeds \`deno.lock\` from npm, pnpm, yarn and Bun lockfiles with exact versions and hashes, migrates pnpm workspace config, and shims \`node\` for tools that shell out to it.
- [Deno 1.22 Release Notes](https://swe.quest/articles/deno-1-22-release-notes-4c57bc88a83acfab.md): Deno · 2022-05-18 · Medium · 7 min read · Runtimes & VMs, TypeScript, JavaScript, Developer tools
  Deno 1.22 changes the default type checking mode from Full to Local across most subcommands, skipping type errors in dependencies to match tsc, with a proposed move to no type checking in \`deno run\` and \`deno cache\` in 1.23.
- [Deno 1.24 Release Notes](https://swe.quest/articles/deno-1-24-release-notes-f57fe884dd776e93.md): Deno · 2022-07-21 · Medium · 9 min read · JavaScript, TypeScript, Runtimes & VMs, Performance engineering
  Deno 1.24 moves all TypeScript emitting to swc and caches type-check results, making \`deno check\` 20% faster cold and 70–90% faster on reruns for codebases like oak.

Browse: [Latest posts](https://swe.quest/index.md) · [Topics](https://swe.quest/tags.md) · [Sources](https://swe.quest/sources.md) · [Topic map](https://swe.quest/map.md) · [Site guide (llms.txt)](https://swe.quest/llms.txt)
