How to give more memory to the language service (Typescript, Vue, etc.)

Question

How to increase the heap size for a language service if it runs out of memory?

Answer 

In versions >= 2025.3:

Use Set memory limit field in Settings | Languages & Frameworks | TypeScript

In versions < 2025.3:

  • in Help | Find action..., type registry
  • open Registry dialog
  • for the TypeScript language service, locate typescript.service.node.arguments key (you can start typing property name to navigate to it)
  • for ESLint, find eslint.service.node.arguments
  • for Vue language service, find typescript.service.lsp.node.arguments
  • add --max_old_space_size option there (--max_old_space_size=4096, for example)

See https://github.com/thlorenz/v8-flags/blob/master/flags-0.11.md#max_old_space_size-0-integer

 

0 out of 0 found this helpful

Please sign in to leave a comment.

Have more questions?

Submit a request