This package provides a consistent TypeScript configuration for projects. It includes two commands: swc-compiler
and swc-runner
.
Install the package globally or locally:
npm install @jterrazz/package-typescript
Use the provided tsconfig.json
in your project:
// tsconfig.json
{
extends: '@jterrazz/package-typescript/tsconfig/node-esm',
compilerOptions: {
// Your custom compiler options here
},
}
swc-compiler
: Compile TypeScript files using SWC.swc-runner
: Execute TypeScript files using SWC.
- The package reads directly from the
tsconfig.json
file, keeping the implementation details hidden. - Consumers don't need to worry about the underlying scripts.
Happy coding!