简体   繁体   中英

How to configure VS Code to use TypeScript already installed

I am getting started with TypeScript and have it installed here C:\Program Files (x86)\Microsoft SDKs\TypeScript

TS 安装和版本

When I try to run tsc VS Code gives this error:

在此处输入图像描述

How to configure VS Code to use one of the versions in there to compile using tsc ? Any version will do fine.

Is there no option other than re-installing using npm?

Thanks in advance.

You probably don't have tsc in your PATH. If you installed Typescript through Node locally, check this SO post: tsc is not recognized as internal or external command . Otherwise, open System Properties and go to Path Variables to set up your PATH ( instructions ).

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM