talira

Pretty TypeScript Errors

Makes TypeScript's error messages readable in VS Code, with highlighted types and links to explanations

open sourceMITfree

A VS Code extension that reformats TypeScript errors in hover messages so long types are readable: the types in each message are syntax highlighted in the editor's theme colours, with a button beside each type that opens its declaration, one that opens the error's explanation on typescript.tv and one that opens it in ts-error-translator in plain English. It handles errors from Node and Deno TypeScript, JSDoc types in JavaScript, React, Solid and Qwik files, Astro, Svelte and Vue files with TypeScript on, and Glint's Ember and Glimmer errors. MIT licensed.

Problems it solves

  • understand long TypeScript type errors in VS Code
  • make TypeScript error messages readable instead of a wall of parentheses
  • find out what a confusing TypeScript error actually means

Features

  • syntax-highlighted types in TypeScript error messages
  • jump to a type's declaration from the error
  • links to explanations on typescript.tv and ts-error-translator
  • works in .ts, .tsx, .js, .vue, .svelte and .astro files

Alternatives

The same job

These do what Pretty TypeScript Errors does.

  1. Error Lens Shows errors and warnings inline at the end of the line in VS Code, with the whole line highlighted
  2. Pylance A performant, feature-rich language server for Python in VS Code

Compare Pretty TypeScript Errors with the top 3