DefinitelyTyped/types/global-npm/global-npm-tests.ts
Waseem Dahman 0e6efc8134 [global-npm] Add types for global-npm (#41705)
* add types for global-npm

* remove reference import
2020-01-20 18:59:45 -05:00

19 lines
424 B
TypeScript

import npm = require('global-npm');
const installPath: string = npm.GLOBAL_NPM_PATH;
const binPath: string = npm.GLOBAL_NPM_BIN;
const list: string[] = npm.fullList;
npm.globalDir;
npm.globalBin;
npm.load({ loglevel: 'silent' }, () => {
npm.commands.install(['typescript'], () => {});
npm.commands.view(['typescript'], true, () => {});
// $ExpectError
npm.commands.install('typescript', () => {});
});