A tiny script to run JS/TS code in the console.
This script executes the src/index.ts
file using tsx and automatically watches for changes.
The simplest way to use the script is by running make
. This command will install dependencies and start the script.
Feel free to edit src/index.ts
—the script will automatically restart upon detecting any changes.
make install
: Installs dependencies and creates thesrc/index.ts
file.make clean
: Removes thenode_modules
directory.make watch
(npm run watch
): Runssrc/index.ts
in watch mode.make exec
(npm run exec
): Executessrc/index.ts
once.make test
(npm run test
): Runs TypeScript checks (tsc --noEmit
) on thesrc
folder.
You can use make
or npm start
as shortcuts for npm run watch
.