Answer the question
In order to leave comments, you need to log in
How to prevent the tsc compiler from making a copy of a file with a .js extension?
I need to call one ts file, but at the same time I need to specify a property that forbids creating, the file that was created during the compilation process, i.e. was customConfig.ts , after calling it with tsc , I got customConfig.js, in the same file directory, what property should be set to tsc when compiling so that it doesn't create customConfig.js?! Thanks
Answer the question
In order to leave comments, you need to log in
tsc is a transpiler. His job is to compile TypeScript to JavaScript, but no more. If you just want to run TypeScript right away, for example for development, then you can use ts-node . Also, if it annoys you that the name is in the same directory, then through tsconfig you can specify the output directory, where the js files will be located.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question