nodemon-ts
v1.0.1
Published
> The purpose of this custom command `nodemon-ts` is to allow developers to compile and excute Typescript files in real time when writing Typescript fils.You don't need to run `tsc`, `ts-node`, or `nodemon` commands anymore.The `nodemon-ts` command brings
Readme
INTRODUCTION
The purpose of this custom command
nodemon-tsis to allow developers to compile and excute Typescript files in real time when writing Typescript fils.You don't need to runtsc,ts-node, ornodemoncommands anymore.Thenodemon-tscommand brings them together.
HOW TO USE
If you are writing a Typescript file named hello.ts like that:
{
console.log("I am the output => Hello World");
}then you can do that in teminal:
nodemon-ts hello.ts
then you can see the following result:
🎆🎆🎆 info: File exists and has read/write permissions
🎆🎆🎆 info: Watching file: hello.ts
🎆🎆🎆 info: Running file: hello.ts
I am the output => Hello Worldif you edit the file again, it will automatically output the compiled file execution results:
🎆🎆🎆 info: Running file: hello.ts
🎆🎆🎆 info: Restarting file: hello.ts
I edit the hello.ts file againThe above is the basic usage of this command, by default, the corresponding compiled js file will not be output. If you want to see the corresponding js file, you can add the -s parameter like that:
nodemon-ts hello.ts -s: by default,es5rules are used to output js files
In addition to, you can customize the es version, like es2015, esnext and so on
nodemon-ts hello.ts -s es2015
