Please type:
npm uninstall -g typescript
instead of
npm uninstall -g tsc
That should solve your problem! :)
Answer from Sohaib Furqan on Stack OverflowPlease type:
npm uninstall -g typescript
instead of
npm uninstall -g tsc
That should solve your problem! :)
FOR WINDOWS
You might have an old TypeScript installation on your computer because of a Microsoft SDK:
cmd>tsc --version
Version 1.0.3.0
If you check the PATH environment variable, you may find an entry like this:
C:\Program Files (x86)\Microsoft SDKs\TypeScript\1.0\
In my case, the uninstallation of "TypeScript Tools for Microsoft Visual Studio 2015" did not remove tsc.exe etc. from this path, probably because it was installed as part of the Windows 10 SDK or something else.
You can remove the entry from the PATH environment variable or at least move it below the entry for Node.js (probably C:\Program Files\nodejs) or nvm (like C:\Users\<username>\AppData\Roaming\nvm) in case you use Node Version Manager. This will prevent that calls to tsc run the ancient TypeScript compiler:
cmd>tsc --version
Version 3.1.3
Don't forget to restart your command line after changes to environment variables for them to take effect!
If you are unsure what binary the tsc command will actually run then use the where command to find out:
cmd>where tsc
C:\Program Files\nodejs\tsc
C:\Program Files\nodejs\tsc.cmd
C:\Program Files (x86)\Microsoft SDKs\TypeScript\1.0\tsc.exe
C:\Program Files (x86)\Microsoft SDKs\TypeScript\1.0\tsc.js
The priority is top to bottom. The first entry in my case is a (Linux) shell script and usually not executable on Windows. The second entry is a Windows Batch script and this is the one that will be executed. It basically invokes Node.js (simplified):
node.exe node_modules\typescript\bin\tsc
OR
You can now uninstall "TypeScript Tools for Microsoft Visual Studio 2015" from the Control Panel in Programs and Features. It was automatically installed with Visual Studio 2015 in my case.
FOR Ubuntu Linux
Uninstall node-typescript To uninstall only node-typescript from Ubuntu 16.04 (Xenial Xerus) run in terminal:
sudo apt-get remove node-typescript
Uninstall node-typescript and dependent packages To uninstall the node-typescript package and any other dependent packages that are no longer needed by Ubuntu Xenial.
sudo apt-get remove --auto-remove node-typescript
Expunge node-typescript If you also want to clear the node-typescript settings and / or data from Ubuntu Xenial then use this command:
sudo apt-get purge node-typescript
To clear the node-typescript settings and / or data files and their Ubuntu Xenial dependent packages, run:
sudo apt-get purge --auto-remove node-typescript
More information about apt-get remove
Advanced Package Tool, or APT, is a free software user interface that works with core libraries to handle the installation and removal of software on Debian, Ubuntu and other Linux distributions. APT simplifies the process of managing software on Unix-like computer systems by automating the retrieval, configuration and installation of software packages, either from precompiled files or by compiling source code.
apt-get is the command-line tool for handling packages, and may be considered the back end user to other tools using the APT library.
apt-get remove is identical to install except that packages are removed instead of installed. Note that removing a package leaves its configuration files on the system. If a plus sign is appended to the package name (with no intervening space), the identified package will be installed instead of removed.
You can now uninstall "TypeScript Tools for Microsoft Visual Studio 2015" from the Control Panel in Programs and Features. It was automatically installed with Visual Studio 2015 in my case.
TypeScript is built into both VS 2013 Update 2 the VS 14 CTP and cannot be separately uninstalled. You could uninstall both of those versions of Visual Studio if it is somehow critical to remove those folders.
The visual studio version of TypeScript does not depend on nodejs. It uses IE for compilation.
You can uninstall the nodejs version using npm uninstall -g typescript if you installed it previously (which you probably didn't).
And then simply install TS from : http://www.microsoft.com/en-us/download/details.aspx?id=34790
To uninstall the version of Typescript used by Visual Studio, use "add/remove programs" in Windows and remove "TypeScript for Visual Studio". It's installed as a program rather than an extension for VS (and as you've noticed, it doesn't use the NodeJs version).
Hi there! I wanna apologize in advance since... well, I know next to nothing about Typescript. I've heard of it and I kind of know what it does + I've installed it via npm, but that's about it. Basically, I found this package on GitHub that I want to install and run, which I've seen uses TS. I don't really know how to use any of the functions here, though, so I'll go over what I have done:
Installed the package to my computer
Installed Node.js, npm, and Typescript
Tried running the
npm install animaljam.jscommand, but failed. It begins installing, but later says it can't find the file (I wonder if there's a way I should be linking it to the folder).
I'm extremely new to all this stuff, and I'm really not looking to get into JavaScript or anything, but I would at least really like to know how to run this program- or what I'm doing wrong. Thanks so much to anyone who can point me in the right direction!