Nova-Client/Solar/Launcher/node_modules/galactus/lib/DestroyerOfModules.d.ts

19 lines
712 B
TypeScript
Raw Normal View History

2023-03-19 20:32:58 +01:00
import { Module, Walker } from 'flora-colossus';
export declare type ShouldKeepModuleTest = (module: Module, isDevDep: boolean) => boolean;
export declare type ModuleMap = Map<string, Module>;
export declare class DestroyerOfModules {
private walker;
private shouldKeepFn;
constructor({rootDirectory, walker, shouldKeepModuleTest}: {
rootDirectory?: string;
walker?: Walker;
shouldKeepModuleTest?: ShouldKeepModuleTest;
});
destroyModule(modulePath: string, moduleMap: ModuleMap): Promise<void>;
collectKeptModules({relativePaths}: {
relativePaths: boolean;
}): Promise<ModuleMap>;
destroy(): Promise<void>;
private shouldKeepModule(module);
}