@eljs/create
Version:
Create a project from a remote template.
40 lines • 850 B
TypeScript
import type { RemoteTemplate } from "../types";
/**
* 下载构造函数
*/
export interface DownloadOptions extends RemoteTemplate {
/**
* 当前工作目录
*/
cwd?: string;
}
export declare class Download {
/**
* 构造函数选项
*/
constructorOptions: DownloadOptions;
/**
* spinner
*/
private _spinner;
constructor(options: DownloadOptions);
download(): Promise<string>;
/**
* 下载 npm 压缩包
* @param name 包名
* @param registry 仓库源
*/
private _downloadNpmTarball;
/**
* 下载 git
* @param url git url
*/
private _downloadGit;
/**
* 安装依赖
* @param cwd 当前工作目录
* @param projectName 项目名称
*/
private _installDependencies;
}
//# sourceMappingURL=download.d.ts.map