@coderesque/resque-scripts-node v2.0.0
@coderesque/resque-scripts-node
Scripts for building and maintaining TypeScript Node.js apps
Install
yarn add --dev --exact @coderesque/resque-scripts-nodeUsage
Add the following scripts to package.json.
{
"scripts": {
"prebuild": "resque-scripts-node test",
"build": "resque-scripts-node build",
"test": "resque-scripts-node test",
"ts:lint": "resque-scripts-node ts-lint",
"ts:test": "resque-scripts-node ts-test",
"ts:watch": "resque-scripts-node ts-watch",
}
}Add a tsconfig.json file in the same folder as package.json.
{
"extends": "@coderesque/typescript-config-node",
"compilerOptions": {
"outDir": "./dist",
"rootDir": "./src"
}
}Tasks
Sequence tasks
These tasks will be run in silent mode, which means the output for each individual task will be minimal.
build
Run all necessary tasks to generate a fresh build in the dist folder.
empty-distts-compilegenerate-licensefilter-dist
test
Run all necessary tasks to test the quality of the project.
ts-lintts-test
Simple tasks
empty-dist (alias: clean)
Empty the dist folder.
filter-dist
Remove unwanted test and source map files from the dist folder.
generate-license
Generate a project license in the dist folder.
ts-compile
Compile TypeScript to JavaScript and put the output in the dist folder.
ts-lint
Lint source files using ESLint.
ts-test
Run tests using Jest.
ts-watch
Re-compile TypeScript to JavaScript and put the output in the dist folder on changes to the source files.
Note
This library is being published with our use cases in mind and is not necessarily meant to be consumed by the broader public. We probably won't take your feature requests unless they align with our own needs.
License
MIT