Skip to content

Commit

Permalink
get some type checking
Browse files Browse the repository at this point in the history
  • Loading branch information
pokey committed Nov 10, 2023
1 parent 673e7cd commit 602a89a
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions packages/common/scripts/my-ts-node.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#!/usr/bin/env node
/* eslint-disable no-undef */
// @ts-check
// Note: type annotations allow type checking and IDEs autocompletion
/*eslint-env node*/
import { spawn } from "child_process";
import { existsSync, mkdirSync, rmdirSync } from "fs";
import { join } from "path";
Expand Down Expand Up @@ -63,7 +65,7 @@ function main() {
runCommand(process.execPath, [outFile, ...args]);
} else {
console.error(`esbuild failed with code ${code}`);
process.exit(code);
process.exit(code ?? undefined);
}
});
}
Expand Down

0 comments on commit 602a89a

Please sign in to comment.