Skip to main content
← VS Code Extension

Code Lens

Travsr adds one blast radius code lens at the top of each supported file (line 1). The lens shows the number of files that would be affected if that file changed, from get_blast_radius.

Travsr code lens and hover card

Lens format​

🩻 blast: 12 files
import { Receipt } from "./receipt";
  • 🩻 blast: is the prefix
  • The count is the number of files in the blast radius
  • Counts above 99 display as 99+
  • The lens is omitted when the count is 0 or the daemon is unavailable

High blast warning​

When the count reaches travsr.blastRiskThreshold (default 20), the lens escalates to a warning so you see the risk before you edit:

⚠️ high blast: 34 files; review before editing

Changing the threshold re-titles the lens without re-querying the daemon. See Settings.

Supported file types​

Code lenses appear in files whose VS Code language is TypeScript, TypeScript React, JavaScript, JavaScript React, Rust, Python, Go, Java, Kotlin, Ruby, PHP, Scala, C++, C, C#, Swift, or Dart.

Clicking the lens​

Clicking the lens opens the Blast Radius panel, which lists every affected file. At the top, an analysis toggle switches between:

  • Structural: single-file structure and best-effort calls from the Phase A parse. Always available, and the default.
  • Semantic: precise cross-file calls and references from Phase B. When semantic analysis is not available for the file's language, the pill reads Semantic ▾, is disabled, and shows an install hint; any prerequisites the project needs are listed under it.

Command​

The panel's command is:

Travsr: Show Blast Radius

It takes the file from the lens or the hover card that invokes it. To check the file you are editing from the command palette or the right-click menu, use Travsr: Check Blast Radius Before Edit instead.