Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
1.0k views
in Technique[技术] by (71.8m points)

typescript - Build:Unknown compiler option 'listemittedfiles'

I get the error as below when building project after uninstalling the TypeScript 2.0. (Visual Studio 2015)

tsc : error TS5023: Build:Unknown compiler option 'listemittedfiles'.

Do you know how to fix it? Thanks,

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

I had my hard times yesterday trying to fix this nasty issue: I finally found out that MSBuild was still using an old TypeScript version instead of the latest one. To fix it for good, you should do the following:

  • Install the updated Visual Studio 2015 TypeScript Tools (2.0.6 at the time of writing)
  • (optionally) remove the TypeScript 1.x references from your PATH environment variable and/or replace them with the new TypeScript 2.x folder path.

Doing this will point MSBuild to the proper TypeScript build, which fully supports the --listEmittedFiles command switch.

For more info regarding this issue I also suggest you to read this article that I've written about such topic and also these two Github threads (affiliation warning: the second one being on the GitHub repo of a book I wrote):


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...