beta.blog

TypeScript: Error TS5013: Unsupported encoding for file ‘file.ts’ (FIX)

by on Jul.22, 2013, under Programming

When attempting to compile one of my TypeScript files in Visual Studio 2012 today, I noticed I received  error messages saying

error TS5013: Unsupported encoding for file 'file.ts'
error TS5004: Could not find file: 'file.ts'

I was unsure why this occured all of sudden. It turned out the encoding of my file had changed, so I simply opened up the file in Notepad++ and changed the encoding from ANSI back to UTF-8. Obviously, some special characters got lost by this conversion, however, the TypeScript file compiled successfully afterwards.


Leave a Reply

*

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!