## API Report File for "@rushstack/heft"

> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).

```ts

import { AsyncParallelHook } from 'tapable';
import { AsyncSeriesBailHook } from 'tapable';
import { AsyncSeriesHook } from 'tapable';
import { AsyncSeriesWaterfallHook } from 'tapable';
import { CommandLineAction } from '@rushstack/ts-command-line';
import { CommandLineFlagParameter } from '@rushstack/ts-command-line';
import { CommandLineIntegerParameter } from '@rushstack/ts-command-line';
import { CommandLineStringParameter } from '@rushstack/ts-command-line';
import { IPackageJson } from '@rushstack/node-core-library';
import { ITerminalProvider } from '@rushstack/node-core-library';
import { SyncHook } from 'tapable';
import { Terminal } from '@rushstack/node-core-library';
import * as webpack from 'webpack';

// @public (undocumented)
export class BuildStageHooks extends StageHooksBase<IBuildStageProperties> {
    // (undocumented)
    readonly bundle: SyncHook<IBundleSubstage>;
    // (undocumented)
    readonly compile: SyncHook<ICompileSubstage>;
    // (undocumented)
    readonly postBuild: SyncHook<IPostBuildSubstage>;
    // (undocumented)
    readonly preCompile: SyncHook<IPreCompileSubstage>;
}

// @public (undocumented)
export class BuildSubstageHooksBase {
    // (undocumented)
    readonly run: AsyncParallelHook;
}

// @public (undocumented)
export class BundleSubstageHooks extends BuildSubstageHooksBase {
    // (undocumented)
    readonly afterConfigureWebpack: AsyncSeriesHook;
    // (undocumented)
    readonly configureApiExtractor: AsyncSeriesWaterfallHook<IApiExtractorConfiguration>;
    // (undocumented)
    readonly configureWebpack: AsyncSeriesWaterfallHook<IWebpackConfiguration>;
}

// @public (undocumented)
export class CleanStageHooks extends StageHooksBase<ICleanStageProperties> {
    // (undocumented)
    readonly deletePath: AsyncSeriesBailHook<string>;
}

// @public (undocumented)
export class CompileSubstageHooks extends BuildSubstageHooksBase {
    // (undocumented)
    readonly afterConfigureCopyStaticAssets: AsyncSeriesHook;
    // (undocumented)
    readonly afterConfigureTypeScript: AsyncSeriesHook;
    // (undocumented)
    readonly configureCopyStaticAssets: AsyncSeriesHook;
    // (undocumented)
    readonly configureTypeScript: AsyncSeriesHook;
}

// @public (undocumented)
export type CopyFromCacheMode = 'hardlink' | 'copy';

// @public (undocumented)
export class DevDeployStageHooks extends StageHooksBase<IDevDeployStageProperties> {
}

// @public (undocumented)
export class HeftConfiguration {
    get buildCacheFolder(): string;
    get buildFolder(): string;
    get compilerPackage(): ICompilerPackage | undefined;
    get heftPackageJson(): IPackageJson;
    // @internal (undocumented)
    static initialize(options: _IHeftConfigurationInitializationOptions): HeftConfiguration;
    get projectHeftDataFolder(): string;
    get projectPackageJson(): IPackageJson;
    get terminal(): Terminal;
    get terminalProvider(): ITerminalProvider;
    }

// @public (undocumented)
export class HeftSession {
    // Warning: (ae-forgotten-export) The symbol "IHeftSessionOptions" needs to be exported by the entry point index.d.ts
    // Warning: (ae-forgotten-export) The symbol "IInternalHeftSessionOptions" needs to be exported by the entry point index.d.ts
    //
    // @internal
    constructor(options: IHeftSessionOptions, internalSessionOptions: IInternalHeftSessionOptions);
    readonly debugMode: boolean;
    // (undocumented)
    readonly hooks: IHeftSessionHooks;
    // @internal (undocumented)
    readonly metricsCollector: _MetricsCollector;
}

// @public (undocumented)
export interface IApiExtractorConfiguration {
    useProjectTypescriptVersion?: boolean;
}

// @public (undocumented)
export interface IBuildStageContext extends IStageContext<BuildStageHooks, IBuildStageProperties> {
}

// @public (undocumented)
export interface IBuildStageProperties {
    // (undocumented)
    lite: boolean;
    // (undocumented)
    locale?: string;
    // (undocumented)
    maxOldSpaceSize?: string;
    // (undocumented)
    production: boolean;
    // (undocumented)
    serveMode: boolean;
    // (undocumented)
    watchMode: boolean;
    // (undocumented)
    webpackStats?: webpack.Stats;
}

// @public (undocumented)
export interface IBuildSubstage<TBuildSubstageHooks extends BuildSubstageHooksBase, TBuildSubstageProperties extends object> {
    // (undocumented)
    hooks: TBuildSubstageHooks;
    // (undocumented)
    properties: TBuildSubstageProperties;
}

// @public (undocumented)
export interface IBundleSubstage extends IBuildSubstage<BundleSubstageHooks, IBundleSubstageProperties> {
}

// @public (undocumented)
export interface IBundleSubstageProperties extends ISharedBundleSubstageWebpackProperties {
    webpackConfiguration?: webpack.Configuration | webpack.Configuration[];
}

// @public (undocumented)
export interface ICleanStageContext extends IStageContext<CleanStageHooks, ICleanStageProperties> {
}

// @public (undocumented)
export interface ICleanStageProperties {
    // (undocumented)
    deleteCache: boolean;
    // (undocumented)
    pathsToDelete: Set<string>;
}

// @public (undocumented)
export interface ICompilerPackage {
    // (undocumented)
    apiExtractorPackagePath: string | undefined;
    // (undocumented)
    eslintPackagePath: string | undefined;
    // (undocumented)
    tslintPackagePath: string | undefined;
    // (undocumented)
    typeScriptPackagePath: string;
}

// @public (undocumented)
export interface ICompileSubstage extends IBuildSubstage<CompileSubstageHooks, ICompileSubstageProperties> {
}

// @public (undocumented)
export interface ICompileSubstageProperties {
    // (undocumented)
    copyStaticAssetsConfiguration: ICopyStaticAssetsConfiguration;
    // (undocumented)
    typeScriptConfiguration: ITypeScriptConfiguration;
}

// @public (undocumented)
export interface ICopyStaticAssetsConfiguration extends ISharedCopyStaticAssetsConfiguration {
    destinationFolderNames: string[];
    sourceFolderName: string;
}

// @public (undocumented)
export interface IDevDeployStageContext extends IStageContext<DevDeployStageHooks, IDevDeployStageProperties> {
}

// @public (undocumented)
export interface IDevDeployStageProperties {
}

// @public (undocumented)
export type IEmitModuleKind = IEmitModuleKindBase<'commonjs' | 'amd' | 'umd' | 'system' | 'es2015' | 'esnext'>;

// @public (undocumented)
export interface IEmitModuleKindBase<TModuleKind> {
    // (undocumented)
    moduleKind: TModuleKind;
    // (undocumented)
    outFolderPath: string;
}

// @public
export interface IHeftActionConfiguration {
}

// @public
export interface IHeftActionConfigurationOptions {
    mergeArrays?: boolean;
}

// @internal (undocumented)
export interface _IHeftConfigurationInitializationOptions {
    cwd: string;
    terminalProvider: ITerminalProvider;
}

// @public (undocumented)
export interface IHeftPlugin<TOptions = void> {
    // (undocumented)
    apply: (heftSession: HeftSession, heftConfiguration: HeftConfiguration, options?: TOptions) => void;
    // (undocumented)
    displayName: string;
}

// @public (undocumented)
export interface IHeftSessionHooks {
    // (undocumented)
    build: SyncHook<IBuildStageContext>;
    // (undocumented)
    clean: SyncHook<ICleanStageContext>;
    // (undocumented)
    devDeploy: SyncHook<IDevDeployStageContext>;
    // (undocumented)
    metricsCollector: MetricsCollectorHooks;
    // (undocumented)
    test: SyncHook<ITestStageContext>;
}

// @public (undocumented)
export interface IMetricsData {
    command: string;
    machineArch: string;
    machineCores: number;
    machineOs: string;
    machineProcessor: string;
    machineTotalMemoryMB: number;
    taskTotalExecutionMs: number;
}

// @internal (undocumented)
export interface _IPerformanceData {
    // (undocumented)
    taskTotalExecutionMs: number;
}

// @public (undocumented)
export interface IPostBuildSubstage extends IBuildSubstage<BuildSubstageHooksBase, {}> {
}

// @public (undocumented)
export interface IPreCompileSubstage extends IBuildSubstage<BuildSubstageHooksBase, {}> {
}

// @public (undocumented)
export interface ISharedBundleSubstageWebpackProperties {
    // (undocumented)
    apiExtractorConfiguration: IApiExtractorConfiguration;
}

// @public (undocumented)
export interface ISharedCopyStaticAssetsConfiguration {
    excludeGlobs?: string[];
    fileExtensions?: string[];
    includeGlobs?: string[];
}

// @public (undocumented)
export interface ISharedTypeScriptConfiguration {
    additionalModuleKindsToEmit?: IEmitModuleKind[] | undefined;
    copyFromCacheMode?: CopyFromCacheMode | undefined;
    emitFolderPathForJest?: string;
    maxWriteParallelism: number;
}

// @public (undocumented)
export interface IStageContext<TStageHooks extends StageHooksBase<TStageProperties>, TStageProperties extends object> {
    // (undocumented)
    hooks: TStageHooks;
    // (undocumented)
    properties: TStageProperties;
}

// @public (undocumented)
export interface ITestStageContext extends IStageContext<TestStageHooks, ITestStageProperties> {
}

// @public (undocumented)
export interface ITestStageProperties {
    // (undocumented)
    production: boolean;
    // (undocumented)
    watchMode: boolean;
}

// @public (undocumented)
export interface ITypeScriptConfiguration extends ISharedTypeScriptConfiguration {
    // (undocumented)
    isLintingEnabled: boolean | undefined;
    // (undocumented)
    tsconfigPaths: string[];
}

// @public (undocumented)
export type IWebpackConfiguration = webpack.Configuration | webpack.Configuration[] | undefined;

// @internal
export class _MetricsCollector {
    flushAndTeardownAsync(): Promise<void>;
    flushAsync(): Promise<void>;
    // (undocumented)
    readonly hooks: MetricsCollectorHooks;
    record(command: string, performanceData?: Partial<_IPerformanceData>): void;
    setStartTime(): void;
    }

// @public
export class MetricsCollectorHooks {
    flush: AsyncParallelHook;
    flushAndTeardown: AsyncParallelHook;
    recordMetric: SyncHook<string, IMetricsData>;
}

// @public (undocumented)
export abstract class StageHooksBase<TStageProperties extends object> {
    // (undocumented)
    readonly afterLoadStageConfiguration: AsyncSeriesHook;
    // (undocumented)
    readonly loadStageConfiguration: AsyncSeriesHook;
    // @beta
    readonly overrideStage: AsyncSeriesBailHook<TStageProperties>;
}

// @public (undocumented)
export class TestStageHooks extends StageHooksBase<ITestStageProperties> {
    // (undocumented)
    readonly configureTest: AsyncSeriesHook;
    // (undocumented)
    readonly run: AsyncParallelHook;
}


// (No @packageDocumentation comment for this package)

```
