I tried this hack: https://github.com/Microsoft/TypeScript/issues/14529 but got other terrible errors so I don't think it worked.
And 2.2 is not available under options here: https://www.microsoft.com/en-us/download/details.aspx?id=55258
"Install-Package Microsoft.TypeScript.MSBuild -Version 2.2.2" did not work either, made the 2.2 show up on the dropdown but only as unavailable. https://www.nuget.org/packages/Microsoft.TypeScript.MSBuild/2.2.2
You can use npm to install TypeScript globally, this means that you can use the tsc command anywhere in your terminal. To do this, run npm install -g typescript . This will install the latest version (currently 4.8). An alternative is to use npx when you have to run tsc for one-off occasions.
TypeScript is installed through the NPM package manager. The -g means it's installed on your system globally so that the TypeScript compiler can be used in any of your projects. Test that the TypeScript is installed correctly by typing tsc -v into your terminal or command prompt.
Run the visual studio installer and modify your visual studio install. Under individual components you will see the versions of typescript available for install.
In my case, I am using VS 2019 and @ken-tucker answer did not worked for me. The Typescript version that I needed (3.6.2) did not appeared in the "Individual components" Tab.
I needed to install from here and restart Visual Studio.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With