@lib/run

1.0.3 • Public • Published

@lib/run

npm version

Compile and run TypeScript in Node with source map support in about 50 lines of code.

Directly run a TypeScript file right now without installing anything but Node:

npx @lib/run script.ts

Or install:

npm install --save-dev @lib/run

Then:

npx run script.ts

Or within a package.json script:

run script.ts

The option -p will require() a JS file before loading the TypeScript compiler. It can be given multiple times:

npx run -p ./preload-1.js -p ./preload-2.js script.ts

License

0BSD, which means use as you wish and no need to mention this project or its author. Consider it public domain in practice.

Readme

Keywords

none

Package Sidebar

Install

npm i @lib/run

Weekly Downloads

4

Version

1.0.3

License

0BSD

Unpacked Size

3.13 kB

Total Files

4

Last publish

Collaborators

  • jjrv
  • isnit