error ts6053 file '* .ts' not found

0

I'm trying to compile all the files .ts but I get that error on my console

error ts6053 file '*.ts' not found

the command that I execute is:

tsc -w *.ts

but if I specify my file, for example tsc -w demo.ts normal compiles (transpiles) the version of my typescript is 2.0.9 , how can I compile all my files .ts automatically (with the -w I achieved that). Thanks

    
asked by Vitmar Aliaga 15.11.2016 в 23:52
source

2 answers

1

Create a tsconfig.json , and execute tsc without arguments, in the directory where they are.

On the TypeScript page there are info on this and several examples.

    
answered by 15.11.2016 в 23:54
1

I got the following solution:

1.- Create a tsconfig.json file where you can set the options for the compiler. Open a terminal, locate over the root directory of your project and execute:

$ tsc --init

message TS6071: Successfully created to tsconfig.json file.

2.- Finally, only the compiler on the directory is still running

$ tsc -p ./ -w

and with the -w you can see how it is automatically compiled if you have made any changes to your files.

    
answered by 08.01.2018 в 19:04