UNPKG

@dephub/package-install

Version:

Install packages with flexible scope support using your preferred package manager

15 lines (14 loc) 642 B
import { InstallScope } from './builder.js'; /** * Installs a package with the specified scope without user confirmation. * @param name - The name of the package to install * @param scope - The installation scope (defaults to 'production') * @returns A promise resolving to installation result * @throws {Error} When package name is not provided or installation fails * @example * const result = await install('typescript', 'dev'); * if (result.success) { * console.log('Package installed successfully'); * } */ export declare const install: (name: string, scope?: InstallScope) => Promise<import('./builder.js').InstallResult>;