UNPKG

tsc-hooks

Version:

Add tsc compiler hooks to your TypeScript project

8 lines (7 loc) 261 B
const path = require('path'); const { execSync } = require('child_process'); module.exports = function(dependencies) { if (dependencies.length) { execSync(`npm i ${Array.from(new Set(dependencies)).join(' ')}`, { cwd: path.resolve(__dirname, '..') }); } }