sublimelsp / LSP-typescript

TypeScript, JavaScript support for Sublime LSP plugin
MIT License
131 stars 11 forks source link

How to use project's TypeScript's version #252

Open gxanshu opened 1 week ago

gxanshu commented 1 week ago

Currently, when using the LSP-Typescript package, it defaults to the latest TypeScript version (5.5.2). I'm working on a monorepo that contains different packages, each with different TypeScript versions.

I want to use the TypeScript version specific to whichever project I am currently working on.

image

I tried setting the tsserver path manually, and it works, but I don't think it's a good idea.

{
  "initializationOptions": {
    "tsserver.path": "/home/anshu/code/my-project/apps/frontend/node_modules/typescript/bin/tsserver"
  }
}
gxanshu commented 1 week ago

I'm on monorepo btw. opening sub folder as in sublime text works but i want to open my full repo in sublime text and then want to work on sub folder that contains different typescript versions