id
int64
0
3.78k
code
stringlengths
13
37.9k
declarations
stringlengths
16
64.6k
3,400
constructor(options: IgnorePluginOptions)
type IgnorePluginOptions = | { /** * A RegExp to test the context (directory) against. */ contextRegExp?: RegExp; /** * A RegExp to test the request against. */ resourceRegExp: RegExp; } | { /** * A filter function for resource and context. */ checkResource: (resource: string, context: string) => boolean; };
3,401
constructor(options: IgnorePluginOptions)
type IgnorePluginOptions = | { /** * A RegExp to test the context (directory) against. */ contextRegExp?: RegExp; /** * A RegExp to test the request against. */ resourceRegExp: RegExp; } | { /** * A filter function for resource and context. */ checkResource: (resource: string, context: string) => boolean; };
3,402
checkIgnore(resolveData: ResolveData): undefined | false
interface ResolveData { contextInfo: ModuleFactoryCreateDataContextInfo; resolveOptions?: ResolveOptionsWebpackOptions; context: string; request: string; assertions?: Record<string, any>; dependencies: ModuleDependency[]; dependencyType: string; createData: Partial<NormalModuleCreateData & { settings: ModuleSettings }>; fileDependencies: LazySet<string>; missingDependencies: LazySet<string>; contextDependencies: LazySet<string>; /** * allow to use the unsafe cache */ cacheable: boolean; }
3,403
getContent(context: Context): string | Source
type Context = string;
3,404
getEndContent(context: Context): undefined | string | Source
type Context = string;
3,405
renderModule( module: Module, renderContext: ChunkRenderContext, hooks: CompilationHooksJavascriptModulesPlugin, factory: boolean ): Source
interface Module { hot: webpack.Hot; }
3,406
renderModule( module: Module, renderContext: ChunkRenderContext, hooks: CompilationHooksJavascriptModulesPlugin, factory: boolean ): Source
class Module extends DependenciesBlock { constructor(type: string, context?: string, layer?: string); type: string; context: null | string; layer: null | string; needId: boolean; debugId: number; resolveOptions: ResolveOptionsWebpackOptions; factoryMeta?: object; useSourceMap: boolean; useSimpleSourceMap: boolean; buildMeta: BuildMeta; buildInfo: Record<string, any>; presentationalDependencies?: Dependency[]; codeGenerationDependencies?: Dependency[]; id: string | number; get hash(): string; get renderedHash(): string; profile: null | ModuleProfile; index: number; index2: number; depth: number; issuer: null | Module; get usedExports(): null | boolean | SortableSet<string>; get optimizationBailout(): ( | string | ((requestShortener: RequestShortener) => string) )[]; get optional(): boolean; addChunk(chunk?: any): boolean; removeChunk(chunk?: any): void; isInChunk(chunk?: any): boolean; isEntryModule(): boolean; getChunks(): Chunk[]; getNumberOfChunks(): number; get chunksIterable(): Iterable<Chunk>; isProvided(exportName: string): null | boolean; get exportsArgument(): string; get moduleArgument(): string; getExportsType( moduleGraph: ModuleGraph, strict: boolean ): "namespace" | "default-only" | "default-with-named" | "dynamic"; addPresentationalDependency(presentationalDependency: Dependency): void; addCodeGenerationDependency(codeGenerationDependency: Dependency): void; addWarning(warning: WebpackError): void; getWarnings(): undefined | Iterable<WebpackError>; getNumberOfWarnings(): number; addError(error: WebpackError): void; getErrors(): undefined | Iterable<WebpackError>; getNumberOfErrors(): number; /** * removes all warnings and errors */ clearWarningsAndErrors(): void; isOptional(moduleGraph: ModuleGraph): boolean; isAccessibleInChunk( chunkGraph: ChunkGraph, chunk: Chunk, ignoreChunk?: Chunk ): boolean; isAccessibleInChunkGroup( chunkGraph: ChunkGraph, chunkGroup: ChunkGroup, ignoreChunk?: Chunk ): boolean; hasReasonForChunk( chunk: Chunk, moduleGraph: ModuleGraph, chunkGraph: ChunkGraph ): boolean; hasReasons(moduleGraph: ModuleGraph, runtime: RuntimeSpec): boolean; needBuild( context: NeedBuildContext, callback: (arg0?: null | WebpackError, arg1?: boolean) => void ): void; needRebuild( fileTimestamps: Map<string, null | number>, contextTimestamps: Map<string, null | number> ): boolean; invalidateBuild(): void; identifier(): string; readableIdentifier(requestShortener: RequestShortener): string; build( options: WebpackOptionsNormalized, compilation: Compilation, resolver: ResolverWithOptions, fs: InputFileSystem, callback: (arg0?: WebpackError) => void ): void; getSourceTypes(): Set<string>; source( dependencyTemplates: DependencyTemplates, runtimeTemplate: RuntimeTemplate, type?: string ): Source; size(type?: string): number; libIdent(options: LibIdentOptions): null | string; nameForCondition(): null | string; getConcatenationBailoutReason( context: ConcatenationBailoutReasonContext ): undefined | string; getSideEffectsConnectionState(moduleGraph: ModuleGraph): ConnectionState; codeGeneration(context: CodeGenerationContext): CodeGenerationResult; chunkCondition(chunk: Chunk, compilation: Compilation): boolean; hasChunkCondition(): boolean; /** * Assuming this module is in the cache. Update the (cached) module with * the fresh module from the factory. Usually updates internal references * and properties. */ updateCacheModule(module: Module): void; /** * Module should be unsafe cached. Get data that's needed for that. * This data will be passed to restoreFromUnsafeCache later. */ getUnsafeCacheData(): object; /** * Assuming this module is in the cache. Remove internal references to allow freeing some memory. */ cleanupForCache(): void; originalSource(): null | Source; addCacheDependencies( fileDependencies: LazySet<string>, contextDependencies: LazySet<string>, missingDependencies: LazySet<string>, buildDependencies: LazySet<string> ): void; get hasEqualsChunks(): any; get isUsed(): any; get errors(): any; get warnings(): any; used: any; }
3,407
renderModule( module: Module, renderContext: ChunkRenderContext, hooks: CompilationHooksJavascriptModulesPlugin, factory: boolean ): Source
interface CompilationHooksJavascriptModulesPlugin { renderModuleContent: SyncWaterfallHook<[Source, Module, ChunkRenderContext]>; renderModuleContainer: SyncWaterfallHook< [Source, Module, ChunkRenderContext] >; renderModulePackage: SyncWaterfallHook<[Source, Module, ChunkRenderContext]>; renderChunk: SyncWaterfallHook<[Source, RenderContext]>; renderMain: SyncWaterfallHook<[Source, RenderContext]>; renderContent: SyncWaterfallHook<[Source, RenderContext]>; render: SyncWaterfallHook<[Source, RenderContext]>; renderStartup: SyncWaterfallHook<[Source, Module, StartupRenderContext]>; renderRequire: SyncWaterfallHook<[string, RenderBootstrapContext]>; inlineInRuntimeBailout: SyncBailHook< [Module, RenderBootstrapContext], string >; embedInRuntimeBailout: SyncBailHook<[Module, RenderContext], string>; strictRuntimeBailout: SyncBailHook<[RenderContext], string>; chunkHash: SyncHook<[Chunk, Hash, ChunkHashContext]>; useSourceMap: SyncBailHook<[Chunk, RenderContext], boolean>; }
3,408
renderModule( module: Module, renderContext: ChunkRenderContext, hooks: CompilationHooksJavascriptModulesPlugin, factory: boolean ): Source
interface ChunkRenderContext { /** * the chunk */ chunk: Chunk; /** * the dependency templates */ dependencyTemplates: DependencyTemplates; /** * the runtime template */ runtimeTemplate: RuntimeTemplate; /** * the module graph */ moduleGraph: ModuleGraph; /** * the chunk graph */ chunkGraph: ChunkGraph; /** * results of code generation */ codeGenerationResults: CodeGenerationResults; /** * init fragments for the chunk */ chunkInitFragments: InitFragment<ChunkRenderContext>[]; /** * rendering in strict context */ strictMode: boolean; }
3,409
renderChunk( renderContext: RenderContext, hooks: CompilationHooksJavascriptModulesPlugin ): Source
interface RenderContext { /** * the chunk */ chunk: Chunk; /** * the dependency templates */ dependencyTemplates: DependencyTemplates; /** * the runtime template */ runtimeTemplate: RuntimeTemplate; /** * the module graph */ moduleGraph: ModuleGraph; /** * the chunk graph */ chunkGraph: ChunkGraph; /** * results of code generation */ codeGenerationResults: CodeGenerationResults; /** * rendering in strict context */ strictMode: boolean; }
3,410
renderChunk( renderContext: RenderContext, hooks: CompilationHooksJavascriptModulesPlugin ): Source
interface CompilationHooksJavascriptModulesPlugin { renderModuleContent: SyncWaterfallHook<[Source, Module, ChunkRenderContext]>; renderModuleContainer: SyncWaterfallHook< [Source, Module, ChunkRenderContext] >; renderModulePackage: SyncWaterfallHook<[Source, Module, ChunkRenderContext]>; renderChunk: SyncWaterfallHook<[Source, RenderContext]>; renderMain: SyncWaterfallHook<[Source, RenderContext]>; renderContent: SyncWaterfallHook<[Source, RenderContext]>; render: SyncWaterfallHook<[Source, RenderContext]>; renderStartup: SyncWaterfallHook<[Source, Module, StartupRenderContext]>; renderRequire: SyncWaterfallHook<[string, RenderBootstrapContext]>; inlineInRuntimeBailout: SyncBailHook< [Module, RenderBootstrapContext], string >; embedInRuntimeBailout: SyncBailHook<[Module, RenderContext], string>; strictRuntimeBailout: SyncBailHook<[RenderContext], string>; chunkHash: SyncHook<[Chunk, Hash, ChunkHashContext]>; useSourceMap: SyncBailHook<[Chunk, RenderContext], boolean>; }
3,411
renderMain( renderContext: MainRenderContext, hooks: CompilationHooksJavascriptModulesPlugin, compilation: Compilation ): Source
class Compilation { /** * Creates an instance of Compilation. */ constructor(compiler: Compiler, params: CompilationParams); hooks: Readonly<{ buildModule: SyncHook<[Module]>; rebuildModule: SyncHook<[Module]>; failedModule: SyncHook<[Module, WebpackError]>; succeedModule: SyncHook<[Module]>; stillValidModule: SyncHook<[Module]>; addEntry: SyncHook<[Dependency, EntryOptions]>; failedEntry: SyncHook<[Dependency, EntryOptions, Error]>; succeedEntry: SyncHook<[Dependency, EntryOptions, Module]>; dependencyReferencedExports: SyncWaterfallHook< [(string[] | ReferencedExport)[], Dependency, RuntimeSpec] >; executeModule: SyncHook<[ExecuteModuleArgument, ExecuteModuleContext]>; prepareModuleExecution: AsyncParallelHook< [ExecuteModuleArgument, ExecuteModuleContext] >; finishModules: AsyncSeriesHook<[Iterable<Module>]>; finishRebuildingModule: AsyncSeriesHook<[Module]>; unseal: SyncHook<[]>; seal: SyncHook<[]>; beforeChunks: SyncHook<[]>; afterChunks: SyncHook<[Iterable<Chunk>]>; optimizeDependencies: SyncBailHook<[Iterable<Module>], any>; afterOptimizeDependencies: SyncHook<[Iterable<Module>]>; optimize: SyncHook<[]>; optimizeModules: SyncBailHook<[Iterable<Module>], any>; afterOptimizeModules: SyncHook<[Iterable<Module>]>; optimizeChunks: SyncBailHook<[Iterable<Chunk>, ChunkGroup[]], any>; afterOptimizeChunks: SyncHook<[Iterable<Chunk>, ChunkGroup[]]>; optimizeTree: AsyncSeriesHook<[Iterable<Chunk>, Iterable<Module>]>; afterOptimizeTree: SyncHook<[Iterable<Chunk>, Iterable<Module>]>; optimizeChunkModules: AsyncSeriesBailHook< [Iterable<Chunk>, Iterable<Module>], any >; afterOptimizeChunkModules: SyncHook<[Iterable<Chunk>, Iterable<Module>]>; shouldRecord: SyncBailHook<[], boolean>; additionalChunkRuntimeRequirements: SyncHook< [Chunk, Set<string>, RuntimeRequirementsContext] >; runtimeRequirementInChunk: HookMap< SyncBailHook<[Chunk, Set<string>, RuntimeRequirementsContext], any> >; additionalModuleRuntimeRequirements: SyncHook< [Module, Set<string>, RuntimeRequirementsContext] >; runtimeRequirementInModule: HookMap< SyncBailHook<[Module, Set<string>, RuntimeRequirementsContext], any> >; additionalTreeRuntimeRequirements: SyncHook< [Chunk, Set<string>, RuntimeRequirementsContext] >; runtimeRequirementInTree: HookMap< SyncBailHook<[Chunk, Set<string>, RuntimeRequirementsContext], any> >; runtimeModule: SyncHook<[RuntimeModule, Chunk]>; reviveModules: SyncHook<[Iterable<Module>, any]>; beforeModuleIds: SyncHook<[Iterable<Module>]>; moduleIds: SyncHook<[Iterable<Module>]>; optimizeModuleIds: SyncHook<[Iterable<Module>]>; afterOptimizeModuleIds: SyncHook<[Iterable<Module>]>; reviveChunks: SyncHook<[Iterable<Chunk>, any]>; beforeChunkIds: SyncHook<[Iterable<Chunk>]>; chunkIds: SyncHook<[Iterable<Chunk>]>; optimizeChunkIds: SyncHook<[Iterable<Chunk>]>; afterOptimizeChunkIds: SyncHook<[Iterable<Chunk>]>; recordModules: SyncHook<[Iterable<Module>, any]>; recordChunks: SyncHook<[Iterable<Chunk>, any]>; optimizeCodeGeneration: SyncHook<[Iterable<Module>]>; beforeModuleHash: SyncHook<[]>; afterModuleHash: SyncHook<[]>; beforeCodeGeneration: SyncHook<[]>; afterCodeGeneration: SyncHook<[]>; beforeRuntimeRequirements: SyncHook<[]>; afterRuntimeRequirements: SyncHook<[]>; beforeHash: SyncHook<[]>; contentHash: SyncHook<[Chunk]>; afterHash: SyncHook<[]>; recordHash: SyncHook<[any]>; record: SyncHook<[Compilation, any]>; beforeModuleAssets: SyncHook<[]>; shouldGenerateChunkAssets: SyncBailHook<[], boolean>; beforeChunkAssets: SyncHook<[]>; additionalChunkAssets: FakeHook< Pick< AsyncSeriesHook<[Set<Chunk>]>, "name" | "tap" | "tapAsync" | "tapPromise" > >; additionalAssets: FakeHook< Pick<AsyncSeriesHook<[]>, "name" | "tap" | "tapAsync" | "tapPromise"> >; optimizeChunkAssets: FakeHook< Pick< AsyncSeriesHook<[Set<Chunk>]>, "name" | "tap" | "tapAsync" | "tapPromise" > >; afterOptimizeChunkAssets: FakeHook< Pick< AsyncSeriesHook<[Set<Chunk>]>, "name" | "tap" | "tapAsync" | "tapPromise" > >; optimizeAssets: AsyncSeriesHook< [CompilationAssets], ProcessAssetsAdditionalOptions >; afterOptimizeAssets: SyncHook<[CompilationAssets]>; processAssets: AsyncSeriesHook< [CompilationAssets], ProcessAssetsAdditionalOptions >; afterProcessAssets: SyncHook<[CompilationAssets]>; processAdditionalAssets: AsyncSeriesHook<[CompilationAssets]>; needAdditionalSeal: SyncBailHook<[], boolean>; afterSeal: AsyncSeriesHook<[]>; renderManifest: SyncWaterfallHook< [RenderManifestEntry[], RenderManifestOptions] >; fullHash: SyncHook<[Hash]>; chunkHash: SyncHook<[Chunk, Hash, ChunkHashContext]>; moduleAsset: SyncHook<[Module, string]>; chunkAsset: SyncHook<[Chunk, string]>; assetPath: SyncWaterfallHook<[string, object, AssetInfo]>; needAdditionalPass: SyncBailHook<[], boolean>; childCompiler: SyncHook<[Compiler, string, number]>; log: SyncBailHook<[string, LogEntry], true>; processWarnings: SyncWaterfallHook<[WebpackError[]]>; processErrors: SyncWaterfallHook<[WebpackError[]]>; statsPreset: HookMap< SyncHook<[Partial<NormalizedStatsOptions>, CreateStatsOptionsContext]> >; statsNormalize: SyncHook< [Partial<NormalizedStatsOptions>, CreateStatsOptionsContext] >; statsFactory: SyncHook<[StatsFactory, NormalizedStatsOptions]>; statsPrinter: SyncHook<[StatsPrinter, NormalizedStatsOptions]>; get normalModuleLoader(): SyncHook<[object, NormalModule]>; }>; name?: string; startTime: any; endTime: any; compiler: Compiler; resolverFactory: ResolverFactory; inputFileSystem: InputFileSystem; fileSystemInfo: FileSystemInfo; valueCacheVersions: Map<string, string | Set<string>>; requestShortener: RequestShortener; compilerPath: string; logger: WebpackLogger; options: WebpackOptionsNormalized; outputOptions: OutputNormalized; bail: boolean; profile: boolean; params: CompilationParams; mainTemplate: MainTemplate; chunkTemplate: ChunkTemplate; runtimeTemplate: RuntimeTemplate; moduleTemplates: { javascript: ModuleTemplate }; moduleMemCaches?: Map<Module, WeakTupleMap<any, any>>; moduleMemCaches2?: Map<Module, WeakTupleMap<any, any>>; moduleGraph: ModuleGraph; chunkGraph: ChunkGraph; codeGenerationResults: CodeGenerationResults; processDependenciesQueue: AsyncQueue<Module, Module, Module>; addModuleQueue: AsyncQueue<Module, string, Module>; factorizeQueue: AsyncQueue< FactorizeModuleOptions, string, Module | ModuleFactoryResult >; buildQueue: AsyncQueue<Module, Module, Module>; rebuildQueue: AsyncQueue<Module, Module, Module>; /** * Modules in value are building during the build of Module in key. * Means value blocking key from finishing. * Needed to detect build cycles. */ creatingModuleDuringBuild: WeakMap<Module, Set<Module>>; entries: Map<string, EntryData>; globalEntry: EntryData; entrypoints: Map<string, Entrypoint>; asyncEntrypoints: Entrypoint[]; chunks: Set<Chunk>; chunkGroups: ChunkGroup[]; namedChunkGroups: Map<string, ChunkGroup>; namedChunks: Map<string, Chunk>; modules: Set<Module>; records: any; additionalChunkAssets: string[]; assets: CompilationAssets; assetsInfo: Map<string, AssetInfo>; errors: WebpackError[]; warnings: WebpackError[]; children: Compilation[]; logging: Map<string, LogEntry[]>; dependencyFactories: Map<DepConstructor, ModuleFactory>; dependencyTemplates: DependencyTemplates; childrenCounters: object; usedChunkIds: Set<string | number>; usedModuleIds: Set<number>; needAdditionalPass: boolean; builtModules: WeakSet<Module>; codeGeneratedModules: WeakSet<Module>; buildTimeExecutedModules: WeakSet<Module>; emittedAssets: Set<string>; comparedForEmitAssets: Set<string>; fileDependencies: LazySet<string>; contextDependencies: LazySet<string>; missingDependencies: LazySet<string>; buildDependencies: LazySet<string>; compilationDependencies: { add: (item?: any) => LazySet<string> }; getStats(): Stats; createStatsOptions( optionsOrPreset: string | StatsOptions, context?: CreateStatsOptionsContext ): NormalizedStatsOptions; createStatsFactory(options?: any): StatsFactory; createStatsPrinter(options?: any): StatsPrinter; getCache(name: string): CacheFacade; getLogger(name: string | (() => string)): WebpackLogger; addModule( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; /** * Fetches a module from a compilation by its identifier */ getModule(module: Module): Module; /** * Attempts to search for a module by its identifier */ findModule(identifier: string): undefined | Module; /** * Schedules a build of the module object */ buildModule( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; processModuleDependencies( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; processModuleDependenciesNonRecursive(module: Module): void; handleModuleCreation( __0: HandleModuleCreationOptions, callback: (err?: null | WebpackError, result?: Module) => void ): void; addModuleChain( context: string, dependency: Dependency, callback: (err?: null | WebpackError, result?: Module) => void ): void; addModuleTree( __0: { /** * context string path */ context: string; /** * dependency used to create Module chain */ dependency: Dependency; /** * additional context info for the root module */ contextInfo?: Partial<ModuleFactoryCreateDataContextInfo>; }, callback: (err?: null | WebpackError, result?: Module) => void ): void; addEntry( context: string, entry: Dependency, optionsOrName: string | EntryOptions, callback: (err?: null | WebpackError, result?: Module) => void ): void; addInclude( context: string, dependency: Dependency, options: EntryOptions, callback: (err?: null | WebpackError, result?: Module) => void ): void; rebuildModule( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; finish(callback?: any): void; unseal(): void; seal(callback: (err?: null | WebpackError) => void): void; reportDependencyErrorsAndWarnings( module: Module, blocks: DependenciesBlock[] ): boolean; codeGeneration(callback?: any): void; processRuntimeRequirements(__0?: { /** * the chunk graph */ chunkGraph?: ChunkGraph; /** * modules */ modules?: Iterable<Module>; /** * chunks */ chunks?: Iterable<Chunk>; /** * codeGenerationResults */ codeGenerationResults?: CodeGenerationResults; /** * chunkGraphEntries */ chunkGraphEntries?: Iterable<Chunk>; }): void; addRuntimeModule( chunk: Chunk, module: RuntimeModule, chunkGraph?: ChunkGraph ): void; /** * If `module` is passed, `loc` and `request` must also be passed. */ addChunkInGroup( groupOptions: string | ChunkGroupOptions, module?: Module, loc?: SyntheticDependencyLocation | RealDependencyLocation, request?: string ): ChunkGroup; addAsyncEntrypoint( options: EntryOptions, module: Module, loc: DependencyLocation, request: string ): Entrypoint; /** * This method first looks to see if a name is provided for a new chunk, * and first looks to see if any named chunks already exist and reuse that chunk instead. */ addChunk(name?: string): Chunk; assignDepth(module: Module): void; assignDepths(modules: Set<Module>): void; getDependencyReferencedExports( dependency: Dependency, runtime: RuntimeSpec ): (string[] | ReferencedExport)[]; removeReasonsOfDependencyBlock( module: Module, block: DependenciesBlockLike ): void; patchChunksAfterReasonRemoval(module: Module, chunk: Chunk): void; removeChunkFromDependencies(block: DependenciesBlock, chunk: Chunk): void; assignRuntimeIds(): void; sortItemsWithChunkIds(): void; summarizeDependencies(): void; createModuleHashes(): void; createHash(): { module: Module; hash: string; runtime: RuntimeSpec; runtimes: RuntimeSpec[]; }[]; fullHash?: string; hash?: string; emitAsset(file: string, source: Source, assetInfo?: AssetInfo): void; updateAsset( file: string, newSourceOrFunction: Source | ((arg0: Source) => Source), assetInfoUpdateOrFunction?: AssetInfo | ((arg0?: AssetInfo) => AssetInfo) ): void; renameAsset(file?: any, newFile?: any): void; deleteAsset(file: string): void; getAssets(): Readonly<Asset>[]; getAsset(name: string): undefined | Readonly<Asset>; clearAssets(): void; createModuleAssets(): void; getRenderManifest(options: RenderManifestOptions): RenderManifestEntry[]; createChunkAssets(callback: (err?: null | WebpackError) => void): void; getPath( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data?: PathData ): string; getPathWithInfo( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data?: PathData ): { path: string; info: AssetInfo }; getAssetPath( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data: PathData ): string; getAssetPathWithInfo( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data: PathData ): { path: string; info: AssetInfo }; getWarnings(): WebpackError[]; getErrors(): WebpackError[]; /** * This function allows you to run another instance of webpack inside of webpack however as * a child with different settings and configurations (if desired) applied. It copies all hooks, plugins * from parent (or top level compiler) and creates a child Compilation */ createChildCompiler( name: string, outputOptions?: OutputNormalized, plugins?: ( | ((this: Compiler, compiler: Compiler) => void) | WebpackPluginInstance )[] ): Compiler; executeModule( module: Module, options: ExecuteModuleOptions, callback: (err?: null | WebpackError, result?: ExecuteModuleResult) => void ): void; checkConstraints(): void; factorizeModule: { ( options: FactorizeModuleOptions & { factoryResult?: false }, callback: (err?: null | WebpackError, result?: Module) => void ): void; ( options: FactorizeModuleOptions & { factoryResult: true }, callback: ( err?: null | WebpackError, result?: ModuleFactoryResult ) => void ): void; }; /** * Add additional assets to the compilation. */ static PROCESS_ASSETS_STAGE_ADDITIONAL: number; /** * Basic preprocessing of assets. */ static PROCESS_ASSETS_STAGE_PRE_PROCESS: number; /** * Derive new assets from existing assets. * Existing assets should not be treated as complete. */ static PROCESS_ASSETS_STAGE_DERIVED: number; /** * Add additional sections to existing assets, like a banner or initialization code. */ static PROCESS_ASSETS_STAGE_ADDITIONS: number; /** * Optimize existing assets in a general way. */ static PROCESS_ASSETS_STAGE_OPTIMIZE: number; /** * Optimize the count of existing assets, e. g. by merging them. * Only assets of the same type should be merged. * For assets of different types see PROCESS_ASSETS_STAGE_OPTIMIZE_INLINE. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_COUNT: number; /** * Optimize the compatibility of existing assets, e. g. add polyfills or vendor-prefixes. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_COMPATIBILITY: number; /** * Optimize the size of existing assets, e. g. by minimizing or omitting whitespace. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_SIZE: number; /** * Add development tooling to assets, e. g. by extracting a SourceMap. */ static PROCESS_ASSETS_STAGE_DEV_TOOLING: number; /** * Optimize the count of existing assets, e. g. by inlining assets of into other assets. * Only assets of different types should be inlined. * For assets of the same type see PROCESS_ASSETS_STAGE_OPTIMIZE_COUNT. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_INLINE: number; /** * Summarize the list of existing assets * e. g. creating an assets manifest of Service Workers. */ static PROCESS_ASSETS_STAGE_SUMMARIZE: number; /** * Optimize the hashes of the assets, e. g. by generating real hashes of the asset content. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_HASH: number; /** * Optimize the transfer of existing assets, e. g. by preparing a compressed (gzip) file as separate asset. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_TRANSFER: number; /** * Analyse existing assets. */ static PROCESS_ASSETS_STAGE_ANALYSE: number; /** * Creating assets for reporting purposes. */ static PROCESS_ASSETS_STAGE_REPORT: number; }
3,412
renderMain( renderContext: MainRenderContext, hooks: CompilationHooksJavascriptModulesPlugin, compilation: Compilation ): Source
interface CompilationHooksJavascriptModulesPlugin { renderModuleContent: SyncWaterfallHook<[Source, Module, ChunkRenderContext]>; renderModuleContainer: SyncWaterfallHook< [Source, Module, ChunkRenderContext] >; renderModulePackage: SyncWaterfallHook<[Source, Module, ChunkRenderContext]>; renderChunk: SyncWaterfallHook<[Source, RenderContext]>; renderMain: SyncWaterfallHook<[Source, RenderContext]>; renderContent: SyncWaterfallHook<[Source, RenderContext]>; render: SyncWaterfallHook<[Source, RenderContext]>; renderStartup: SyncWaterfallHook<[Source, Module, StartupRenderContext]>; renderRequire: SyncWaterfallHook<[string, RenderBootstrapContext]>; inlineInRuntimeBailout: SyncBailHook< [Module, RenderBootstrapContext], string >; embedInRuntimeBailout: SyncBailHook<[Module, RenderContext], string>; strictRuntimeBailout: SyncBailHook<[RenderContext], string>; chunkHash: SyncHook<[Chunk, Hash, ChunkHashContext]>; useSourceMap: SyncBailHook<[Chunk, RenderContext], boolean>; }
3,413
renderMain( renderContext: MainRenderContext, hooks: CompilationHooksJavascriptModulesPlugin, compilation: Compilation ): Source
interface MainRenderContext { /** * the chunk */ chunk: Chunk; /** * the dependency templates */ dependencyTemplates: DependencyTemplates; /** * the runtime template */ runtimeTemplate: RuntimeTemplate; /** * the module graph */ moduleGraph: ModuleGraph; /** * the chunk graph */ chunkGraph: ChunkGraph; /** * results of code generation */ codeGenerationResults: CodeGenerationResults; /** * hash to be used for render call */ hash: string; /** * rendering in strict context */ strictMode: boolean; }
3,414
updateHashWithBootstrap( hash: Hash, renderContext: RenderBootstrapContext, hooks: CompilationHooksJavascriptModulesPlugin ): void
class Hash { constructor(); /** * Update hash {@link https://nodejs.org/api/crypto.html#crypto_hash_update_data_inputencoding} */ update(data: string | Buffer, inputEncoding?: string): Hash; /** * Calculates the digest {@link https://nodejs.org/api/crypto.html#crypto_hash_digest_encoding} */ digest(encoding?: string): string | Buffer; }
3,415
updateHashWithBootstrap( hash: Hash, renderContext: RenderBootstrapContext, hooks: CompilationHooksJavascriptModulesPlugin ): void
interface RenderBootstrapContext { /** * the chunk */ chunk: Chunk; /** * results of code generation */ codeGenerationResults: CodeGenerationResults; /** * the runtime template */ runtimeTemplate: RuntimeTemplate; /** * the module graph */ moduleGraph: ModuleGraph; /** * the chunk graph */ chunkGraph: ChunkGraph; /** * hash to be used for render call */ hash: string; }
3,416
updateHashWithBootstrap( hash: Hash, renderContext: RenderBootstrapContext, hooks: CompilationHooksJavascriptModulesPlugin ): void
interface CompilationHooksJavascriptModulesPlugin { renderModuleContent: SyncWaterfallHook<[Source, Module, ChunkRenderContext]>; renderModuleContainer: SyncWaterfallHook< [Source, Module, ChunkRenderContext] >; renderModulePackage: SyncWaterfallHook<[Source, Module, ChunkRenderContext]>; renderChunk: SyncWaterfallHook<[Source, RenderContext]>; renderMain: SyncWaterfallHook<[Source, RenderContext]>; renderContent: SyncWaterfallHook<[Source, RenderContext]>; render: SyncWaterfallHook<[Source, RenderContext]>; renderStartup: SyncWaterfallHook<[Source, Module, StartupRenderContext]>; renderRequire: SyncWaterfallHook<[string, RenderBootstrapContext]>; inlineInRuntimeBailout: SyncBailHook< [Module, RenderBootstrapContext], string >; embedInRuntimeBailout: SyncBailHook<[Module, RenderContext], string>; strictRuntimeBailout: SyncBailHook<[RenderContext], string>; chunkHash: SyncHook<[Chunk, Hash, ChunkHashContext]>; useSourceMap: SyncBailHook<[Chunk, RenderContext], boolean>; }
3,417
renderBootstrap( renderContext: RenderBootstrapContext, hooks: CompilationHooksJavascriptModulesPlugin ): { header: string[]; beforeStartup: string[]; startup: string[]; afterStartup: string[]; allowInlineStartup: boolean; }
interface RenderBootstrapContext { /** * the chunk */ chunk: Chunk; /** * results of code generation */ codeGenerationResults: CodeGenerationResults; /** * the runtime template */ runtimeTemplate: RuntimeTemplate; /** * the module graph */ moduleGraph: ModuleGraph; /** * the chunk graph */ chunkGraph: ChunkGraph; /** * hash to be used for render call */ hash: string; }
3,418
renderBootstrap( renderContext: RenderBootstrapContext, hooks: CompilationHooksJavascriptModulesPlugin ): { header: string[]; beforeStartup: string[]; startup: string[]; afterStartup: string[]; allowInlineStartup: boolean; }
interface CompilationHooksJavascriptModulesPlugin { renderModuleContent: SyncWaterfallHook<[Source, Module, ChunkRenderContext]>; renderModuleContainer: SyncWaterfallHook< [Source, Module, ChunkRenderContext] >; renderModulePackage: SyncWaterfallHook<[Source, Module, ChunkRenderContext]>; renderChunk: SyncWaterfallHook<[Source, RenderContext]>; renderMain: SyncWaterfallHook<[Source, RenderContext]>; renderContent: SyncWaterfallHook<[Source, RenderContext]>; render: SyncWaterfallHook<[Source, RenderContext]>; renderStartup: SyncWaterfallHook<[Source, Module, StartupRenderContext]>; renderRequire: SyncWaterfallHook<[string, RenderBootstrapContext]>; inlineInRuntimeBailout: SyncBailHook< [Module, RenderBootstrapContext], string >; embedInRuntimeBailout: SyncBailHook<[Module, RenderContext], string>; strictRuntimeBailout: SyncBailHook<[RenderContext], string>; chunkHash: SyncHook<[Chunk, Hash, ChunkHashContext]>; useSourceMap: SyncBailHook<[Chunk, RenderContext], boolean>; }
3,419
renderRequire( renderContext: RenderBootstrapContext, hooks: CompilationHooksJavascriptModulesPlugin ): string
interface RenderBootstrapContext { /** * the chunk */ chunk: Chunk; /** * results of code generation */ codeGenerationResults: CodeGenerationResults; /** * the runtime template */ runtimeTemplate: RuntimeTemplate; /** * the module graph */ moduleGraph: ModuleGraph; /** * the chunk graph */ chunkGraph: ChunkGraph; /** * hash to be used for render call */ hash: string; }
3,420
renderRequire( renderContext: RenderBootstrapContext, hooks: CompilationHooksJavascriptModulesPlugin ): string
interface CompilationHooksJavascriptModulesPlugin { renderModuleContent: SyncWaterfallHook<[Source, Module, ChunkRenderContext]>; renderModuleContainer: SyncWaterfallHook< [Source, Module, ChunkRenderContext] >; renderModulePackage: SyncWaterfallHook<[Source, Module, ChunkRenderContext]>; renderChunk: SyncWaterfallHook<[Source, RenderContext]>; renderMain: SyncWaterfallHook<[Source, RenderContext]>; renderContent: SyncWaterfallHook<[Source, RenderContext]>; render: SyncWaterfallHook<[Source, RenderContext]>; renderStartup: SyncWaterfallHook<[Source, Module, StartupRenderContext]>; renderRequire: SyncWaterfallHook<[string, RenderBootstrapContext]>; inlineInRuntimeBailout: SyncBailHook< [Module, RenderBootstrapContext], string >; embedInRuntimeBailout: SyncBailHook<[Module, RenderContext], string>; strictRuntimeBailout: SyncBailHook<[RenderContext], string>; chunkHash: SyncHook<[Chunk, Hash, ChunkHashContext]>; useSourceMap: SyncBailHook<[Chunk, RenderContext], boolean>; }
3,421
static getCompilationHooks( compilation: Compilation ): CompilationHooksJavascriptModulesPlugin
class Compilation { /** * Creates an instance of Compilation. */ constructor(compiler: Compiler, params: CompilationParams); hooks: Readonly<{ buildModule: SyncHook<[Module]>; rebuildModule: SyncHook<[Module]>; failedModule: SyncHook<[Module, WebpackError]>; succeedModule: SyncHook<[Module]>; stillValidModule: SyncHook<[Module]>; addEntry: SyncHook<[Dependency, EntryOptions]>; failedEntry: SyncHook<[Dependency, EntryOptions, Error]>; succeedEntry: SyncHook<[Dependency, EntryOptions, Module]>; dependencyReferencedExports: SyncWaterfallHook< [(string[] | ReferencedExport)[], Dependency, RuntimeSpec] >; executeModule: SyncHook<[ExecuteModuleArgument, ExecuteModuleContext]>; prepareModuleExecution: AsyncParallelHook< [ExecuteModuleArgument, ExecuteModuleContext] >; finishModules: AsyncSeriesHook<[Iterable<Module>]>; finishRebuildingModule: AsyncSeriesHook<[Module]>; unseal: SyncHook<[]>; seal: SyncHook<[]>; beforeChunks: SyncHook<[]>; afterChunks: SyncHook<[Iterable<Chunk>]>; optimizeDependencies: SyncBailHook<[Iterable<Module>], any>; afterOptimizeDependencies: SyncHook<[Iterable<Module>]>; optimize: SyncHook<[]>; optimizeModules: SyncBailHook<[Iterable<Module>], any>; afterOptimizeModules: SyncHook<[Iterable<Module>]>; optimizeChunks: SyncBailHook<[Iterable<Chunk>, ChunkGroup[]], any>; afterOptimizeChunks: SyncHook<[Iterable<Chunk>, ChunkGroup[]]>; optimizeTree: AsyncSeriesHook<[Iterable<Chunk>, Iterable<Module>]>; afterOptimizeTree: SyncHook<[Iterable<Chunk>, Iterable<Module>]>; optimizeChunkModules: AsyncSeriesBailHook< [Iterable<Chunk>, Iterable<Module>], any >; afterOptimizeChunkModules: SyncHook<[Iterable<Chunk>, Iterable<Module>]>; shouldRecord: SyncBailHook<[], boolean>; additionalChunkRuntimeRequirements: SyncHook< [Chunk, Set<string>, RuntimeRequirementsContext] >; runtimeRequirementInChunk: HookMap< SyncBailHook<[Chunk, Set<string>, RuntimeRequirementsContext], any> >; additionalModuleRuntimeRequirements: SyncHook< [Module, Set<string>, RuntimeRequirementsContext] >; runtimeRequirementInModule: HookMap< SyncBailHook<[Module, Set<string>, RuntimeRequirementsContext], any> >; additionalTreeRuntimeRequirements: SyncHook< [Chunk, Set<string>, RuntimeRequirementsContext] >; runtimeRequirementInTree: HookMap< SyncBailHook<[Chunk, Set<string>, RuntimeRequirementsContext], any> >; runtimeModule: SyncHook<[RuntimeModule, Chunk]>; reviveModules: SyncHook<[Iterable<Module>, any]>; beforeModuleIds: SyncHook<[Iterable<Module>]>; moduleIds: SyncHook<[Iterable<Module>]>; optimizeModuleIds: SyncHook<[Iterable<Module>]>; afterOptimizeModuleIds: SyncHook<[Iterable<Module>]>; reviveChunks: SyncHook<[Iterable<Chunk>, any]>; beforeChunkIds: SyncHook<[Iterable<Chunk>]>; chunkIds: SyncHook<[Iterable<Chunk>]>; optimizeChunkIds: SyncHook<[Iterable<Chunk>]>; afterOptimizeChunkIds: SyncHook<[Iterable<Chunk>]>; recordModules: SyncHook<[Iterable<Module>, any]>; recordChunks: SyncHook<[Iterable<Chunk>, any]>; optimizeCodeGeneration: SyncHook<[Iterable<Module>]>; beforeModuleHash: SyncHook<[]>; afterModuleHash: SyncHook<[]>; beforeCodeGeneration: SyncHook<[]>; afterCodeGeneration: SyncHook<[]>; beforeRuntimeRequirements: SyncHook<[]>; afterRuntimeRequirements: SyncHook<[]>; beforeHash: SyncHook<[]>; contentHash: SyncHook<[Chunk]>; afterHash: SyncHook<[]>; recordHash: SyncHook<[any]>; record: SyncHook<[Compilation, any]>; beforeModuleAssets: SyncHook<[]>; shouldGenerateChunkAssets: SyncBailHook<[], boolean>; beforeChunkAssets: SyncHook<[]>; additionalChunkAssets: FakeHook< Pick< AsyncSeriesHook<[Set<Chunk>]>, "name" | "tap" | "tapAsync" | "tapPromise" > >; additionalAssets: FakeHook< Pick<AsyncSeriesHook<[]>, "name" | "tap" | "tapAsync" | "tapPromise"> >; optimizeChunkAssets: FakeHook< Pick< AsyncSeriesHook<[Set<Chunk>]>, "name" | "tap" | "tapAsync" | "tapPromise" > >; afterOptimizeChunkAssets: FakeHook< Pick< AsyncSeriesHook<[Set<Chunk>]>, "name" | "tap" | "tapAsync" | "tapPromise" > >; optimizeAssets: AsyncSeriesHook< [CompilationAssets], ProcessAssetsAdditionalOptions >; afterOptimizeAssets: SyncHook<[CompilationAssets]>; processAssets: AsyncSeriesHook< [CompilationAssets], ProcessAssetsAdditionalOptions >; afterProcessAssets: SyncHook<[CompilationAssets]>; processAdditionalAssets: AsyncSeriesHook<[CompilationAssets]>; needAdditionalSeal: SyncBailHook<[], boolean>; afterSeal: AsyncSeriesHook<[]>; renderManifest: SyncWaterfallHook< [RenderManifestEntry[], RenderManifestOptions] >; fullHash: SyncHook<[Hash]>; chunkHash: SyncHook<[Chunk, Hash, ChunkHashContext]>; moduleAsset: SyncHook<[Module, string]>; chunkAsset: SyncHook<[Chunk, string]>; assetPath: SyncWaterfallHook<[string, object, AssetInfo]>; needAdditionalPass: SyncBailHook<[], boolean>; childCompiler: SyncHook<[Compiler, string, number]>; log: SyncBailHook<[string, LogEntry], true>; processWarnings: SyncWaterfallHook<[WebpackError[]]>; processErrors: SyncWaterfallHook<[WebpackError[]]>; statsPreset: HookMap< SyncHook<[Partial<NormalizedStatsOptions>, CreateStatsOptionsContext]> >; statsNormalize: SyncHook< [Partial<NormalizedStatsOptions>, CreateStatsOptionsContext] >; statsFactory: SyncHook<[StatsFactory, NormalizedStatsOptions]>; statsPrinter: SyncHook<[StatsPrinter, NormalizedStatsOptions]>; get normalModuleLoader(): SyncHook<[object, NormalModule]>; }>; name?: string; startTime: any; endTime: any; compiler: Compiler; resolverFactory: ResolverFactory; inputFileSystem: InputFileSystem; fileSystemInfo: FileSystemInfo; valueCacheVersions: Map<string, string | Set<string>>; requestShortener: RequestShortener; compilerPath: string; logger: WebpackLogger; options: WebpackOptionsNormalized; outputOptions: OutputNormalized; bail: boolean; profile: boolean; params: CompilationParams; mainTemplate: MainTemplate; chunkTemplate: ChunkTemplate; runtimeTemplate: RuntimeTemplate; moduleTemplates: { javascript: ModuleTemplate }; moduleMemCaches?: Map<Module, WeakTupleMap<any, any>>; moduleMemCaches2?: Map<Module, WeakTupleMap<any, any>>; moduleGraph: ModuleGraph; chunkGraph: ChunkGraph; codeGenerationResults: CodeGenerationResults; processDependenciesQueue: AsyncQueue<Module, Module, Module>; addModuleQueue: AsyncQueue<Module, string, Module>; factorizeQueue: AsyncQueue< FactorizeModuleOptions, string, Module | ModuleFactoryResult >; buildQueue: AsyncQueue<Module, Module, Module>; rebuildQueue: AsyncQueue<Module, Module, Module>; /** * Modules in value are building during the build of Module in key. * Means value blocking key from finishing. * Needed to detect build cycles. */ creatingModuleDuringBuild: WeakMap<Module, Set<Module>>; entries: Map<string, EntryData>; globalEntry: EntryData; entrypoints: Map<string, Entrypoint>; asyncEntrypoints: Entrypoint[]; chunks: Set<Chunk>; chunkGroups: ChunkGroup[]; namedChunkGroups: Map<string, ChunkGroup>; namedChunks: Map<string, Chunk>; modules: Set<Module>; records: any; additionalChunkAssets: string[]; assets: CompilationAssets; assetsInfo: Map<string, AssetInfo>; errors: WebpackError[]; warnings: WebpackError[]; children: Compilation[]; logging: Map<string, LogEntry[]>; dependencyFactories: Map<DepConstructor, ModuleFactory>; dependencyTemplates: DependencyTemplates; childrenCounters: object; usedChunkIds: Set<string | number>; usedModuleIds: Set<number>; needAdditionalPass: boolean; builtModules: WeakSet<Module>; codeGeneratedModules: WeakSet<Module>; buildTimeExecutedModules: WeakSet<Module>; emittedAssets: Set<string>; comparedForEmitAssets: Set<string>; fileDependencies: LazySet<string>; contextDependencies: LazySet<string>; missingDependencies: LazySet<string>; buildDependencies: LazySet<string>; compilationDependencies: { add: (item?: any) => LazySet<string> }; getStats(): Stats; createStatsOptions( optionsOrPreset: string | StatsOptions, context?: CreateStatsOptionsContext ): NormalizedStatsOptions; createStatsFactory(options?: any): StatsFactory; createStatsPrinter(options?: any): StatsPrinter; getCache(name: string): CacheFacade; getLogger(name: string | (() => string)): WebpackLogger; addModule( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; /** * Fetches a module from a compilation by its identifier */ getModule(module: Module): Module; /** * Attempts to search for a module by its identifier */ findModule(identifier: string): undefined | Module; /** * Schedules a build of the module object */ buildModule( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; processModuleDependencies( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; processModuleDependenciesNonRecursive(module: Module): void; handleModuleCreation( __0: HandleModuleCreationOptions, callback: (err?: null | WebpackError, result?: Module) => void ): void; addModuleChain( context: string, dependency: Dependency, callback: (err?: null | WebpackError, result?: Module) => void ): void; addModuleTree( __0: { /** * context string path */ context: string; /** * dependency used to create Module chain */ dependency: Dependency; /** * additional context info for the root module */ contextInfo?: Partial<ModuleFactoryCreateDataContextInfo>; }, callback: (err?: null | WebpackError, result?: Module) => void ): void; addEntry( context: string, entry: Dependency, optionsOrName: string | EntryOptions, callback: (err?: null | WebpackError, result?: Module) => void ): void; addInclude( context: string, dependency: Dependency, options: EntryOptions, callback: (err?: null | WebpackError, result?: Module) => void ): void; rebuildModule( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; finish(callback?: any): void; unseal(): void; seal(callback: (err?: null | WebpackError) => void): void; reportDependencyErrorsAndWarnings( module: Module, blocks: DependenciesBlock[] ): boolean; codeGeneration(callback?: any): void; processRuntimeRequirements(__0?: { /** * the chunk graph */ chunkGraph?: ChunkGraph; /** * modules */ modules?: Iterable<Module>; /** * chunks */ chunks?: Iterable<Chunk>; /** * codeGenerationResults */ codeGenerationResults?: CodeGenerationResults; /** * chunkGraphEntries */ chunkGraphEntries?: Iterable<Chunk>; }): void; addRuntimeModule( chunk: Chunk, module: RuntimeModule, chunkGraph?: ChunkGraph ): void; /** * If `module` is passed, `loc` and `request` must also be passed. */ addChunkInGroup( groupOptions: string | ChunkGroupOptions, module?: Module, loc?: SyntheticDependencyLocation | RealDependencyLocation, request?: string ): ChunkGroup; addAsyncEntrypoint( options: EntryOptions, module: Module, loc: DependencyLocation, request: string ): Entrypoint; /** * This method first looks to see if a name is provided for a new chunk, * and first looks to see if any named chunks already exist and reuse that chunk instead. */ addChunk(name?: string): Chunk; assignDepth(module: Module): void; assignDepths(modules: Set<Module>): void; getDependencyReferencedExports( dependency: Dependency, runtime: RuntimeSpec ): (string[] | ReferencedExport)[]; removeReasonsOfDependencyBlock( module: Module, block: DependenciesBlockLike ): void; patchChunksAfterReasonRemoval(module: Module, chunk: Chunk): void; removeChunkFromDependencies(block: DependenciesBlock, chunk: Chunk): void; assignRuntimeIds(): void; sortItemsWithChunkIds(): void; summarizeDependencies(): void; createModuleHashes(): void; createHash(): { module: Module; hash: string; runtime: RuntimeSpec; runtimes: RuntimeSpec[]; }[]; fullHash?: string; hash?: string; emitAsset(file: string, source: Source, assetInfo?: AssetInfo): void; updateAsset( file: string, newSourceOrFunction: Source | ((arg0: Source) => Source), assetInfoUpdateOrFunction?: AssetInfo | ((arg0?: AssetInfo) => AssetInfo) ): void; renameAsset(file?: any, newFile?: any): void; deleteAsset(file: string): void; getAssets(): Readonly<Asset>[]; getAsset(name: string): undefined | Readonly<Asset>; clearAssets(): void; createModuleAssets(): void; getRenderManifest(options: RenderManifestOptions): RenderManifestEntry[]; createChunkAssets(callback: (err?: null | WebpackError) => void): void; getPath( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data?: PathData ): string; getPathWithInfo( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data?: PathData ): { path: string; info: AssetInfo }; getAssetPath( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data: PathData ): string; getAssetPathWithInfo( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data: PathData ): { path: string; info: AssetInfo }; getWarnings(): WebpackError[]; getErrors(): WebpackError[]; /** * This function allows you to run another instance of webpack inside of webpack however as * a child with different settings and configurations (if desired) applied. It copies all hooks, plugins * from parent (or top level compiler) and creates a child Compilation */ createChildCompiler( name: string, outputOptions?: OutputNormalized, plugins?: ( | ((this: Compiler, compiler: Compiler) => void) | WebpackPluginInstance )[] ): Compiler; executeModule( module: Module, options: ExecuteModuleOptions, callback: (err?: null | WebpackError, result?: ExecuteModuleResult) => void ): void; checkConstraints(): void; factorizeModule: { ( options: FactorizeModuleOptions & { factoryResult?: false }, callback: (err?: null | WebpackError, result?: Module) => void ): void; ( options: FactorizeModuleOptions & { factoryResult: true }, callback: ( err?: null | WebpackError, result?: ModuleFactoryResult ) => void ): void; }; /** * Add additional assets to the compilation. */ static PROCESS_ASSETS_STAGE_ADDITIONAL: number; /** * Basic preprocessing of assets. */ static PROCESS_ASSETS_STAGE_PRE_PROCESS: number; /** * Derive new assets from existing assets. * Existing assets should not be treated as complete. */ static PROCESS_ASSETS_STAGE_DERIVED: number; /** * Add additional sections to existing assets, like a banner or initialization code. */ static PROCESS_ASSETS_STAGE_ADDITIONS: number; /** * Optimize existing assets in a general way. */ static PROCESS_ASSETS_STAGE_OPTIMIZE: number; /** * Optimize the count of existing assets, e. g. by merging them. * Only assets of the same type should be merged. * For assets of different types see PROCESS_ASSETS_STAGE_OPTIMIZE_INLINE. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_COUNT: number; /** * Optimize the compatibility of existing assets, e. g. add polyfills or vendor-prefixes. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_COMPATIBILITY: number; /** * Optimize the size of existing assets, e. g. by minimizing or omitting whitespace. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_SIZE: number; /** * Add development tooling to assets, e. g. by extracting a SourceMap. */ static PROCESS_ASSETS_STAGE_DEV_TOOLING: number; /** * Optimize the count of existing assets, e. g. by inlining assets of into other assets. * Only assets of different types should be inlined. * For assets of the same type see PROCESS_ASSETS_STAGE_OPTIMIZE_COUNT. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_INLINE: number; /** * Summarize the list of existing assets * e. g. creating an assets manifest of Service Workers. */ static PROCESS_ASSETS_STAGE_SUMMARIZE: number; /** * Optimize the hashes of the assets, e. g. by generating real hashes of the asset content. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_HASH: number; /** * Optimize the transfer of existing assets, e. g. by preparing a compressed (gzip) file as separate asset. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_TRANSFER: number; /** * Analyse existing assets. */ static PROCESS_ASSETS_STAGE_ANALYSE: number; /** * Creating assets for reporting purposes. */ static PROCESS_ASSETS_STAGE_REPORT: number; }
3,422
(chunk: Chunk, chunkGraph: ChunkGraph) => boolean
class Chunk { constructor(name?: string, backCompat?: boolean); id: null | string | number; ids: null | (string | number)[]; debugId: number; name: string; idNameHints: SortableSet<string>; preventIntegration: boolean; filenameTemplate: | null | string | ((arg0: PathData, arg1?: AssetInfo) => string); cssFilenameTemplate: | null | string | ((arg0: PathData, arg1?: AssetInfo) => string); runtime: RuntimeSpec; files: Set<string>; auxiliaryFiles: Set<string>; rendered: boolean; hash?: string; contentHash: Record<string, string>; renderedHash?: string; chunkReason?: string; extraAsync: boolean; get entryModule(): Module; hasEntryModule(): boolean; addModule(module: Module): boolean; removeModule(module: Module): void; getNumberOfModules(): number; get modulesIterable(): Iterable<Module>; compareTo(otherChunk: Chunk): 0 | 1 | -1; containsModule(module: Module): boolean; getModules(): Module[]; remove(): void; moveModule(module: Module, otherChunk: Chunk): void; integrate(otherChunk: Chunk): boolean; canBeIntegrated(otherChunk: Chunk): boolean; isEmpty(): boolean; modulesSize(): number; size(options?: ChunkSizeOptions): number; integratedSize(otherChunk: Chunk, options: ChunkSizeOptions): number; getChunkModuleMaps(filterFn: (m: Module) => boolean): ChunkModuleMaps; hasModuleInGraph( filterFn: (m: Module) => boolean, filterChunkFn?: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): boolean; getChunkMaps(realHash: boolean): ChunkMaps; hasRuntime(): boolean; canBeInitial(): boolean; isOnlyInitial(): boolean; getEntryOptions(): undefined | EntryOptions; addGroup(chunkGroup: ChunkGroup): void; removeGroup(chunkGroup: ChunkGroup): void; isInGroup(chunkGroup: ChunkGroup): boolean; getNumberOfGroups(): number; get groupsIterable(): Iterable<ChunkGroup>; disconnectFromGroups(): void; split(newChunk: Chunk): void; updateHash(hash: Hash, chunkGraph: ChunkGraph): void; getAllAsyncChunks(): Set<Chunk>; getAllInitialChunks(): Set<Chunk>; getAllReferencedChunks(): Set<Chunk>; getAllReferencedAsyncEntrypoints(): Set<Entrypoint>; hasAsyncChunks(): boolean; getChildIdsByOrders( chunkGraph: ChunkGraph, filterFn?: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): Record<string, (string | number)[]>; getChildrenOfTypeInOrder( chunkGraph: ChunkGraph, type: string ): { onChunks: Chunk[]; chunks: Set<Chunk> }[]; getChildIdsByOrdersMap( chunkGraph: ChunkGraph, includeDirectChildren?: boolean, filterFn?: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): Record<string | number, Record<string, (string | number)[]>>; }
3,423
(chunk: Chunk, chunkGraph: ChunkGraph) => boolean
class ChunkGraph { constructor(moduleGraph: ModuleGraph, hashFunction?: string | typeof Hash); moduleGraph: ModuleGraph; connectChunkAndModule(chunk: Chunk, module: Module): void; disconnectChunkAndModule(chunk: Chunk, module: Module): void; disconnectChunk(chunk: Chunk): void; attachModules(chunk: Chunk, modules: Iterable<Module>): void; attachRuntimeModules(chunk: Chunk, modules: Iterable<RuntimeModule>): void; attachFullHashModules(chunk: Chunk, modules: Iterable<RuntimeModule>): void; attachDependentHashModules( chunk: Chunk, modules: Iterable<RuntimeModule> ): void; replaceModule(oldModule: Module, newModule: Module): void; isModuleInChunk(module: Module, chunk: Chunk): boolean; isModuleInChunkGroup(module: Module, chunkGroup: ChunkGroup): boolean; isEntryModule(module: Module): boolean; getModuleChunksIterable(module: Module): Iterable<Chunk>; getOrderedModuleChunksIterable( module: Module, sortFn: (arg0: Chunk, arg1: Chunk) => 0 | 1 | -1 ): Iterable<Chunk>; getModuleChunks(module: Module): Chunk[]; getNumberOfModuleChunks(module: Module): number; getModuleRuntimes(module: Module): RuntimeSpecSet; getNumberOfChunkModules(chunk: Chunk): number; getNumberOfChunkFullHashModules(chunk: Chunk): number; getChunkModulesIterable(chunk: Chunk): Iterable<Module>; getChunkModulesIterableBySourceType( chunk: Chunk, sourceType: string ): undefined | Iterable<Module>; setChunkModuleSourceTypes( chunk: Chunk, module: Module, sourceTypes: Set<string> ): void; getChunkModuleSourceTypes(chunk: Chunk, module: Module): Set<string>; getModuleSourceTypes(module: Module): Set<string>; getOrderedChunkModulesIterable( chunk: Chunk, comparator: (arg0: Module, arg1: Module) => 0 | 1 | -1 ): Iterable<Module>; getOrderedChunkModulesIterableBySourceType( chunk: Chunk, sourceType: string, comparator: (arg0: Module, arg1: Module) => 0 | 1 | -1 ): undefined | Iterable<Module>; getChunkModules(chunk: Chunk): Module[]; getOrderedChunkModules( chunk: Chunk, comparator: (arg0: Module, arg1: Module) => 0 | 1 | -1 ): Module[]; getChunkModuleIdMap( chunk: Chunk, filterFn: (m: Module) => boolean, includeAllChunks?: boolean ): Record<string | number, (string | number)[]>; getChunkModuleRenderedHashMap( chunk: Chunk, filterFn: (m: Module) => boolean, hashLength?: number, includeAllChunks?: boolean ): Record<string | number, Record<string | number, string>>; getChunkConditionMap( chunk: Chunk, filterFn: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): Record<string | number, boolean>; hasModuleInGraph( chunk: Chunk, filterFn: (m: Module) => boolean, filterChunkFn?: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): boolean; compareChunks(chunkA: Chunk, chunkB: Chunk): 0 | 1 | -1; getChunkModulesSize(chunk: Chunk): number; getChunkModulesSizes(chunk: Chunk): Record<string, number>; getChunkRootModules(chunk: Chunk): Module[]; getChunkSize(chunk: Chunk, options?: ChunkSizeOptions): number; getIntegratedChunksSize( chunkA: Chunk, chunkB: Chunk, options?: ChunkSizeOptions ): number; canChunksBeIntegrated(chunkA: Chunk, chunkB: Chunk): boolean; integrateChunks(chunkA: Chunk, chunkB: Chunk): void; upgradeDependentToFullHashModules(chunk: Chunk): void; isEntryModuleInChunk(module: Module, chunk: Chunk): boolean; connectChunkAndEntryModule( chunk: Chunk, module: Module, entrypoint?: Entrypoint ): void; connectChunkAndRuntimeModule(chunk: Chunk, module: RuntimeModule): void; addFullHashModuleToChunk(chunk: Chunk, module: RuntimeModule): void; addDependentHashModuleToChunk(chunk: Chunk, module: RuntimeModule): void; disconnectChunkAndEntryModule(chunk: Chunk, module: Module): void; disconnectChunkAndRuntimeModule(chunk: Chunk, module: RuntimeModule): void; disconnectEntryModule(module: Module): void; disconnectEntries(chunk: Chunk): void; getNumberOfEntryModules(chunk: Chunk): number; getNumberOfRuntimeModules(chunk: Chunk): number; getChunkEntryModulesIterable(chunk: Chunk): Iterable<Module>; getChunkEntryDependentChunksIterable(chunk: Chunk): Iterable<Chunk>; hasChunkEntryDependentChunks(chunk: Chunk): boolean; getChunkRuntimeModulesIterable(chunk: Chunk): Iterable<RuntimeModule>; getChunkRuntimeModulesInOrder(chunk: Chunk): RuntimeModule[]; getChunkFullHashModulesIterable( chunk: Chunk ): undefined | Iterable<RuntimeModule>; getChunkFullHashModulesSet( chunk: Chunk ): undefined | ReadonlySet<RuntimeModule>; getChunkDependentHashModulesIterable( chunk: Chunk ): undefined | Iterable<RuntimeModule>; getChunkEntryModulesWithChunkGroupIterable( chunk: Chunk ): Iterable<[Module, undefined | Entrypoint]>; getBlockChunkGroup(depBlock: AsyncDependenciesBlock): ChunkGroup; connectBlockAndChunkGroup( depBlock: AsyncDependenciesBlock, chunkGroup: ChunkGroup ): void; disconnectChunkGroup(chunkGroup: ChunkGroup): void; getModuleId(module: Module): string | number; setModuleId(module: Module, id: string | number): void; getRuntimeId(runtime: string): string | number; setRuntimeId(runtime: string, id: string | number): void; hasModuleHashes(module: Module, runtime: RuntimeSpec): boolean; getModuleHash(module: Module, runtime: RuntimeSpec): string; getRenderedModuleHash(module: Module, runtime: RuntimeSpec): string; setModuleHashes( module: Module, runtime: RuntimeSpec, hash: string, renderedHash: string ): void; addModuleRuntimeRequirements( module: Module, runtime: RuntimeSpec, items: Set<string>, transferOwnership?: boolean ): void; addChunkRuntimeRequirements(chunk: Chunk, items: Set<string>): void; addTreeRuntimeRequirements(chunk: Chunk, items: Iterable<string>): void; getModuleRuntimeRequirements( module: Module, runtime: RuntimeSpec ): ReadonlySet<string>; getChunkRuntimeRequirements(chunk: Chunk): ReadonlySet<string>; getModuleGraphHash( module: Module, runtime: RuntimeSpec, withConnections?: boolean ): string; getModuleGraphHashBigInt( module: Module, runtime: RuntimeSpec, withConnections?: boolean ): bigint; getTreeRuntimeRequirements(chunk: Chunk): ReadonlySet<string>; static getChunkGraphForModule( module: Module, deprecateMessage: string, deprecationCode: string ): ChunkGraph; static setChunkGraphForModule(module: Module, chunkGraph: ChunkGraph): void; static clearChunkGraphForModule(module: Module): void; static getChunkGraphForChunk( chunk: Chunk, deprecateMessage: string, deprecationCode: string ): ChunkGraph; static setChunkGraphForChunk(chunk: Chunk, chunkGraph: ChunkGraph): void; static clearChunkGraphForChunk(chunk: Chunk): void; }
3,424
static getCompilationHooks( compilation: Compilation ): JsonpCompilationPluginHooks
class Compilation { /** * Creates an instance of Compilation. */ constructor(compiler: Compiler, params: CompilationParams); hooks: Readonly<{ buildModule: SyncHook<[Module]>; rebuildModule: SyncHook<[Module]>; failedModule: SyncHook<[Module, WebpackError]>; succeedModule: SyncHook<[Module]>; stillValidModule: SyncHook<[Module]>; addEntry: SyncHook<[Dependency, EntryOptions]>; failedEntry: SyncHook<[Dependency, EntryOptions, Error]>; succeedEntry: SyncHook<[Dependency, EntryOptions, Module]>; dependencyReferencedExports: SyncWaterfallHook< [(string[] | ReferencedExport)[], Dependency, RuntimeSpec] >; executeModule: SyncHook<[ExecuteModuleArgument, ExecuteModuleContext]>; prepareModuleExecution: AsyncParallelHook< [ExecuteModuleArgument, ExecuteModuleContext] >; finishModules: AsyncSeriesHook<[Iterable<Module>]>; finishRebuildingModule: AsyncSeriesHook<[Module]>; unseal: SyncHook<[]>; seal: SyncHook<[]>; beforeChunks: SyncHook<[]>; afterChunks: SyncHook<[Iterable<Chunk>]>; optimizeDependencies: SyncBailHook<[Iterable<Module>], any>; afterOptimizeDependencies: SyncHook<[Iterable<Module>]>; optimize: SyncHook<[]>; optimizeModules: SyncBailHook<[Iterable<Module>], any>; afterOptimizeModules: SyncHook<[Iterable<Module>]>; optimizeChunks: SyncBailHook<[Iterable<Chunk>, ChunkGroup[]], any>; afterOptimizeChunks: SyncHook<[Iterable<Chunk>, ChunkGroup[]]>; optimizeTree: AsyncSeriesHook<[Iterable<Chunk>, Iterable<Module>]>; afterOptimizeTree: SyncHook<[Iterable<Chunk>, Iterable<Module>]>; optimizeChunkModules: AsyncSeriesBailHook< [Iterable<Chunk>, Iterable<Module>], any >; afterOptimizeChunkModules: SyncHook<[Iterable<Chunk>, Iterable<Module>]>; shouldRecord: SyncBailHook<[], boolean>; additionalChunkRuntimeRequirements: SyncHook< [Chunk, Set<string>, RuntimeRequirementsContext] >; runtimeRequirementInChunk: HookMap< SyncBailHook<[Chunk, Set<string>, RuntimeRequirementsContext], any> >; additionalModuleRuntimeRequirements: SyncHook< [Module, Set<string>, RuntimeRequirementsContext] >; runtimeRequirementInModule: HookMap< SyncBailHook<[Module, Set<string>, RuntimeRequirementsContext], any> >; additionalTreeRuntimeRequirements: SyncHook< [Chunk, Set<string>, RuntimeRequirementsContext] >; runtimeRequirementInTree: HookMap< SyncBailHook<[Chunk, Set<string>, RuntimeRequirementsContext], any> >; runtimeModule: SyncHook<[RuntimeModule, Chunk]>; reviveModules: SyncHook<[Iterable<Module>, any]>; beforeModuleIds: SyncHook<[Iterable<Module>]>; moduleIds: SyncHook<[Iterable<Module>]>; optimizeModuleIds: SyncHook<[Iterable<Module>]>; afterOptimizeModuleIds: SyncHook<[Iterable<Module>]>; reviveChunks: SyncHook<[Iterable<Chunk>, any]>; beforeChunkIds: SyncHook<[Iterable<Chunk>]>; chunkIds: SyncHook<[Iterable<Chunk>]>; optimizeChunkIds: SyncHook<[Iterable<Chunk>]>; afterOptimizeChunkIds: SyncHook<[Iterable<Chunk>]>; recordModules: SyncHook<[Iterable<Module>, any]>; recordChunks: SyncHook<[Iterable<Chunk>, any]>; optimizeCodeGeneration: SyncHook<[Iterable<Module>]>; beforeModuleHash: SyncHook<[]>; afterModuleHash: SyncHook<[]>; beforeCodeGeneration: SyncHook<[]>; afterCodeGeneration: SyncHook<[]>; beforeRuntimeRequirements: SyncHook<[]>; afterRuntimeRequirements: SyncHook<[]>; beforeHash: SyncHook<[]>; contentHash: SyncHook<[Chunk]>; afterHash: SyncHook<[]>; recordHash: SyncHook<[any]>; record: SyncHook<[Compilation, any]>; beforeModuleAssets: SyncHook<[]>; shouldGenerateChunkAssets: SyncBailHook<[], boolean>; beforeChunkAssets: SyncHook<[]>; additionalChunkAssets: FakeHook< Pick< AsyncSeriesHook<[Set<Chunk>]>, "name" | "tap" | "tapAsync" | "tapPromise" > >; additionalAssets: FakeHook< Pick<AsyncSeriesHook<[]>, "name" | "tap" | "tapAsync" | "tapPromise"> >; optimizeChunkAssets: FakeHook< Pick< AsyncSeriesHook<[Set<Chunk>]>, "name" | "tap" | "tapAsync" | "tapPromise" > >; afterOptimizeChunkAssets: FakeHook< Pick< AsyncSeriesHook<[Set<Chunk>]>, "name" | "tap" | "tapAsync" | "tapPromise" > >; optimizeAssets: AsyncSeriesHook< [CompilationAssets], ProcessAssetsAdditionalOptions >; afterOptimizeAssets: SyncHook<[CompilationAssets]>; processAssets: AsyncSeriesHook< [CompilationAssets], ProcessAssetsAdditionalOptions >; afterProcessAssets: SyncHook<[CompilationAssets]>; processAdditionalAssets: AsyncSeriesHook<[CompilationAssets]>; needAdditionalSeal: SyncBailHook<[], boolean>; afterSeal: AsyncSeriesHook<[]>; renderManifest: SyncWaterfallHook< [RenderManifestEntry[], RenderManifestOptions] >; fullHash: SyncHook<[Hash]>; chunkHash: SyncHook<[Chunk, Hash, ChunkHashContext]>; moduleAsset: SyncHook<[Module, string]>; chunkAsset: SyncHook<[Chunk, string]>; assetPath: SyncWaterfallHook<[string, object, AssetInfo]>; needAdditionalPass: SyncBailHook<[], boolean>; childCompiler: SyncHook<[Compiler, string, number]>; log: SyncBailHook<[string, LogEntry], true>; processWarnings: SyncWaterfallHook<[WebpackError[]]>; processErrors: SyncWaterfallHook<[WebpackError[]]>; statsPreset: HookMap< SyncHook<[Partial<NormalizedStatsOptions>, CreateStatsOptionsContext]> >; statsNormalize: SyncHook< [Partial<NormalizedStatsOptions>, CreateStatsOptionsContext] >; statsFactory: SyncHook<[StatsFactory, NormalizedStatsOptions]>; statsPrinter: SyncHook<[StatsPrinter, NormalizedStatsOptions]>; get normalModuleLoader(): SyncHook<[object, NormalModule]>; }>; name?: string; startTime: any; endTime: any; compiler: Compiler; resolverFactory: ResolverFactory; inputFileSystem: InputFileSystem; fileSystemInfo: FileSystemInfo; valueCacheVersions: Map<string, string | Set<string>>; requestShortener: RequestShortener; compilerPath: string; logger: WebpackLogger; options: WebpackOptionsNormalized; outputOptions: OutputNormalized; bail: boolean; profile: boolean; params: CompilationParams; mainTemplate: MainTemplate; chunkTemplate: ChunkTemplate; runtimeTemplate: RuntimeTemplate; moduleTemplates: { javascript: ModuleTemplate }; moduleMemCaches?: Map<Module, WeakTupleMap<any, any>>; moduleMemCaches2?: Map<Module, WeakTupleMap<any, any>>; moduleGraph: ModuleGraph; chunkGraph: ChunkGraph; codeGenerationResults: CodeGenerationResults; processDependenciesQueue: AsyncQueue<Module, Module, Module>; addModuleQueue: AsyncQueue<Module, string, Module>; factorizeQueue: AsyncQueue< FactorizeModuleOptions, string, Module | ModuleFactoryResult >; buildQueue: AsyncQueue<Module, Module, Module>; rebuildQueue: AsyncQueue<Module, Module, Module>; /** * Modules in value are building during the build of Module in key. * Means value blocking key from finishing. * Needed to detect build cycles. */ creatingModuleDuringBuild: WeakMap<Module, Set<Module>>; entries: Map<string, EntryData>; globalEntry: EntryData; entrypoints: Map<string, Entrypoint>; asyncEntrypoints: Entrypoint[]; chunks: Set<Chunk>; chunkGroups: ChunkGroup[]; namedChunkGroups: Map<string, ChunkGroup>; namedChunks: Map<string, Chunk>; modules: Set<Module>; records: any; additionalChunkAssets: string[]; assets: CompilationAssets; assetsInfo: Map<string, AssetInfo>; errors: WebpackError[]; warnings: WebpackError[]; children: Compilation[]; logging: Map<string, LogEntry[]>; dependencyFactories: Map<DepConstructor, ModuleFactory>; dependencyTemplates: DependencyTemplates; childrenCounters: object; usedChunkIds: Set<string | number>; usedModuleIds: Set<number>; needAdditionalPass: boolean; builtModules: WeakSet<Module>; codeGeneratedModules: WeakSet<Module>; buildTimeExecutedModules: WeakSet<Module>; emittedAssets: Set<string>; comparedForEmitAssets: Set<string>; fileDependencies: LazySet<string>; contextDependencies: LazySet<string>; missingDependencies: LazySet<string>; buildDependencies: LazySet<string>; compilationDependencies: { add: (item?: any) => LazySet<string> }; getStats(): Stats; createStatsOptions( optionsOrPreset: string | StatsOptions, context?: CreateStatsOptionsContext ): NormalizedStatsOptions; createStatsFactory(options?: any): StatsFactory; createStatsPrinter(options?: any): StatsPrinter; getCache(name: string): CacheFacade; getLogger(name: string | (() => string)): WebpackLogger; addModule( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; /** * Fetches a module from a compilation by its identifier */ getModule(module: Module): Module; /** * Attempts to search for a module by its identifier */ findModule(identifier: string): undefined | Module; /** * Schedules a build of the module object */ buildModule( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; processModuleDependencies( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; processModuleDependenciesNonRecursive(module: Module): void; handleModuleCreation( __0: HandleModuleCreationOptions, callback: (err?: null | WebpackError, result?: Module) => void ): void; addModuleChain( context: string, dependency: Dependency, callback: (err?: null | WebpackError, result?: Module) => void ): void; addModuleTree( __0: { /** * context string path */ context: string; /** * dependency used to create Module chain */ dependency: Dependency; /** * additional context info for the root module */ contextInfo?: Partial<ModuleFactoryCreateDataContextInfo>; }, callback: (err?: null | WebpackError, result?: Module) => void ): void; addEntry( context: string, entry: Dependency, optionsOrName: string | EntryOptions, callback: (err?: null | WebpackError, result?: Module) => void ): void; addInclude( context: string, dependency: Dependency, options: EntryOptions, callback: (err?: null | WebpackError, result?: Module) => void ): void; rebuildModule( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; finish(callback?: any): void; unseal(): void; seal(callback: (err?: null | WebpackError) => void): void; reportDependencyErrorsAndWarnings( module: Module, blocks: DependenciesBlock[] ): boolean; codeGeneration(callback?: any): void; processRuntimeRequirements(__0?: { /** * the chunk graph */ chunkGraph?: ChunkGraph; /** * modules */ modules?: Iterable<Module>; /** * chunks */ chunks?: Iterable<Chunk>; /** * codeGenerationResults */ codeGenerationResults?: CodeGenerationResults; /** * chunkGraphEntries */ chunkGraphEntries?: Iterable<Chunk>; }): void; addRuntimeModule( chunk: Chunk, module: RuntimeModule, chunkGraph?: ChunkGraph ): void; /** * If `module` is passed, `loc` and `request` must also be passed. */ addChunkInGroup( groupOptions: string | ChunkGroupOptions, module?: Module, loc?: SyntheticDependencyLocation | RealDependencyLocation, request?: string ): ChunkGroup; addAsyncEntrypoint( options: EntryOptions, module: Module, loc: DependencyLocation, request: string ): Entrypoint; /** * This method first looks to see if a name is provided for a new chunk, * and first looks to see if any named chunks already exist and reuse that chunk instead. */ addChunk(name?: string): Chunk; assignDepth(module: Module): void; assignDepths(modules: Set<Module>): void; getDependencyReferencedExports( dependency: Dependency, runtime: RuntimeSpec ): (string[] | ReferencedExport)[]; removeReasonsOfDependencyBlock( module: Module, block: DependenciesBlockLike ): void; patchChunksAfterReasonRemoval(module: Module, chunk: Chunk): void; removeChunkFromDependencies(block: DependenciesBlock, chunk: Chunk): void; assignRuntimeIds(): void; sortItemsWithChunkIds(): void; summarizeDependencies(): void; createModuleHashes(): void; createHash(): { module: Module; hash: string; runtime: RuntimeSpec; runtimes: RuntimeSpec[]; }[]; fullHash?: string; hash?: string; emitAsset(file: string, source: Source, assetInfo?: AssetInfo): void; updateAsset( file: string, newSourceOrFunction: Source | ((arg0: Source) => Source), assetInfoUpdateOrFunction?: AssetInfo | ((arg0?: AssetInfo) => AssetInfo) ): void; renameAsset(file?: any, newFile?: any): void; deleteAsset(file: string): void; getAssets(): Readonly<Asset>[]; getAsset(name: string): undefined | Readonly<Asset>; clearAssets(): void; createModuleAssets(): void; getRenderManifest(options: RenderManifestOptions): RenderManifestEntry[]; createChunkAssets(callback: (err?: null | WebpackError) => void): void; getPath( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data?: PathData ): string; getPathWithInfo( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data?: PathData ): { path: string; info: AssetInfo }; getAssetPath( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data: PathData ): string; getAssetPathWithInfo( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data: PathData ): { path: string; info: AssetInfo }; getWarnings(): WebpackError[]; getErrors(): WebpackError[]; /** * This function allows you to run another instance of webpack inside of webpack however as * a child with different settings and configurations (if desired) applied. It copies all hooks, plugins * from parent (or top level compiler) and creates a child Compilation */ createChildCompiler( name: string, outputOptions?: OutputNormalized, plugins?: ( | ((this: Compiler, compiler: Compiler) => void) | WebpackPluginInstance )[] ): Compiler; executeModule( module: Module, options: ExecuteModuleOptions, callback: (err?: null | WebpackError, result?: ExecuteModuleResult) => void ): void; checkConstraints(): void; factorizeModule: { ( options: FactorizeModuleOptions & { factoryResult?: false }, callback: (err?: null | WebpackError, result?: Module) => void ): void; ( options: FactorizeModuleOptions & { factoryResult: true }, callback: ( err?: null | WebpackError, result?: ModuleFactoryResult ) => void ): void; }; /** * Add additional assets to the compilation. */ static PROCESS_ASSETS_STAGE_ADDITIONAL: number; /** * Basic preprocessing of assets. */ static PROCESS_ASSETS_STAGE_PRE_PROCESS: number; /** * Derive new assets from existing assets. * Existing assets should not be treated as complete. */ static PROCESS_ASSETS_STAGE_DERIVED: number; /** * Add additional sections to existing assets, like a banner or initialization code. */ static PROCESS_ASSETS_STAGE_ADDITIONS: number; /** * Optimize existing assets in a general way. */ static PROCESS_ASSETS_STAGE_OPTIMIZE: number; /** * Optimize the count of existing assets, e. g. by merging them. * Only assets of the same type should be merged. * For assets of different types see PROCESS_ASSETS_STAGE_OPTIMIZE_INLINE. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_COUNT: number; /** * Optimize the compatibility of existing assets, e. g. add polyfills or vendor-prefixes. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_COMPATIBILITY: number; /** * Optimize the size of existing assets, e. g. by minimizing or omitting whitespace. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_SIZE: number; /** * Add development tooling to assets, e. g. by extracting a SourceMap. */ static PROCESS_ASSETS_STAGE_DEV_TOOLING: number; /** * Optimize the count of existing assets, e. g. by inlining assets of into other assets. * Only assets of different types should be inlined. * For assets of the same type see PROCESS_ASSETS_STAGE_OPTIMIZE_COUNT. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_INLINE: number; /** * Summarize the list of existing assets * e. g. creating an assets manifest of Service Workers. */ static PROCESS_ASSETS_STAGE_SUMMARIZE: number; /** * Optimize the hashes of the assets, e. g. by generating real hashes of the asset content. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_HASH: number; /** * Optimize the transfer of existing assets, e. g. by preparing a compressed (gzip) file as separate asset. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_TRANSFER: number; /** * Analyse existing assets. */ static PROCESS_ASSETS_STAGE_ANALYSE: number; /** * Creating assets for reporting purposes. */ static PROCESS_ASSETS_STAGE_REPORT: number; }
3,425
(warning: StatsError, textValue: string) => boolean
type StatsError = KnownStatsError & Record<string, any>;
3,426
(arg0: Compilation) => WebpackError[]
class Compilation { /** * Creates an instance of Compilation. */ constructor(compiler: Compiler, params: CompilationParams); hooks: Readonly<{ buildModule: SyncHook<[Module]>; rebuildModule: SyncHook<[Module]>; failedModule: SyncHook<[Module, WebpackError]>; succeedModule: SyncHook<[Module]>; stillValidModule: SyncHook<[Module]>; addEntry: SyncHook<[Dependency, EntryOptions]>; failedEntry: SyncHook<[Dependency, EntryOptions, Error]>; succeedEntry: SyncHook<[Dependency, EntryOptions, Module]>; dependencyReferencedExports: SyncWaterfallHook< [(string[] | ReferencedExport)[], Dependency, RuntimeSpec] >; executeModule: SyncHook<[ExecuteModuleArgument, ExecuteModuleContext]>; prepareModuleExecution: AsyncParallelHook< [ExecuteModuleArgument, ExecuteModuleContext] >; finishModules: AsyncSeriesHook<[Iterable<Module>]>; finishRebuildingModule: AsyncSeriesHook<[Module]>; unseal: SyncHook<[]>; seal: SyncHook<[]>; beforeChunks: SyncHook<[]>; afterChunks: SyncHook<[Iterable<Chunk>]>; optimizeDependencies: SyncBailHook<[Iterable<Module>], any>; afterOptimizeDependencies: SyncHook<[Iterable<Module>]>; optimize: SyncHook<[]>; optimizeModules: SyncBailHook<[Iterable<Module>], any>; afterOptimizeModules: SyncHook<[Iterable<Module>]>; optimizeChunks: SyncBailHook<[Iterable<Chunk>, ChunkGroup[]], any>; afterOptimizeChunks: SyncHook<[Iterable<Chunk>, ChunkGroup[]]>; optimizeTree: AsyncSeriesHook<[Iterable<Chunk>, Iterable<Module>]>; afterOptimizeTree: SyncHook<[Iterable<Chunk>, Iterable<Module>]>; optimizeChunkModules: AsyncSeriesBailHook< [Iterable<Chunk>, Iterable<Module>], any >; afterOptimizeChunkModules: SyncHook<[Iterable<Chunk>, Iterable<Module>]>; shouldRecord: SyncBailHook<[], boolean>; additionalChunkRuntimeRequirements: SyncHook< [Chunk, Set<string>, RuntimeRequirementsContext] >; runtimeRequirementInChunk: HookMap< SyncBailHook<[Chunk, Set<string>, RuntimeRequirementsContext], any> >; additionalModuleRuntimeRequirements: SyncHook< [Module, Set<string>, RuntimeRequirementsContext] >; runtimeRequirementInModule: HookMap< SyncBailHook<[Module, Set<string>, RuntimeRequirementsContext], any> >; additionalTreeRuntimeRequirements: SyncHook< [Chunk, Set<string>, RuntimeRequirementsContext] >; runtimeRequirementInTree: HookMap< SyncBailHook<[Chunk, Set<string>, RuntimeRequirementsContext], any> >; runtimeModule: SyncHook<[RuntimeModule, Chunk]>; reviveModules: SyncHook<[Iterable<Module>, any]>; beforeModuleIds: SyncHook<[Iterable<Module>]>; moduleIds: SyncHook<[Iterable<Module>]>; optimizeModuleIds: SyncHook<[Iterable<Module>]>; afterOptimizeModuleIds: SyncHook<[Iterable<Module>]>; reviveChunks: SyncHook<[Iterable<Chunk>, any]>; beforeChunkIds: SyncHook<[Iterable<Chunk>]>; chunkIds: SyncHook<[Iterable<Chunk>]>; optimizeChunkIds: SyncHook<[Iterable<Chunk>]>; afterOptimizeChunkIds: SyncHook<[Iterable<Chunk>]>; recordModules: SyncHook<[Iterable<Module>, any]>; recordChunks: SyncHook<[Iterable<Chunk>, any]>; optimizeCodeGeneration: SyncHook<[Iterable<Module>]>; beforeModuleHash: SyncHook<[]>; afterModuleHash: SyncHook<[]>; beforeCodeGeneration: SyncHook<[]>; afterCodeGeneration: SyncHook<[]>; beforeRuntimeRequirements: SyncHook<[]>; afterRuntimeRequirements: SyncHook<[]>; beforeHash: SyncHook<[]>; contentHash: SyncHook<[Chunk]>; afterHash: SyncHook<[]>; recordHash: SyncHook<[any]>; record: SyncHook<[Compilation, any]>; beforeModuleAssets: SyncHook<[]>; shouldGenerateChunkAssets: SyncBailHook<[], boolean>; beforeChunkAssets: SyncHook<[]>; additionalChunkAssets: FakeHook< Pick< AsyncSeriesHook<[Set<Chunk>]>, "name" | "tap" | "tapAsync" | "tapPromise" > >; additionalAssets: FakeHook< Pick<AsyncSeriesHook<[]>, "name" | "tap" | "tapAsync" | "tapPromise"> >; optimizeChunkAssets: FakeHook< Pick< AsyncSeriesHook<[Set<Chunk>]>, "name" | "tap" | "tapAsync" | "tapPromise" > >; afterOptimizeChunkAssets: FakeHook< Pick< AsyncSeriesHook<[Set<Chunk>]>, "name" | "tap" | "tapAsync" | "tapPromise" > >; optimizeAssets: AsyncSeriesHook< [CompilationAssets], ProcessAssetsAdditionalOptions >; afterOptimizeAssets: SyncHook<[CompilationAssets]>; processAssets: AsyncSeriesHook< [CompilationAssets], ProcessAssetsAdditionalOptions >; afterProcessAssets: SyncHook<[CompilationAssets]>; processAdditionalAssets: AsyncSeriesHook<[CompilationAssets]>; needAdditionalSeal: SyncBailHook<[], boolean>; afterSeal: AsyncSeriesHook<[]>; renderManifest: SyncWaterfallHook< [RenderManifestEntry[], RenderManifestOptions] >; fullHash: SyncHook<[Hash]>; chunkHash: SyncHook<[Chunk, Hash, ChunkHashContext]>; moduleAsset: SyncHook<[Module, string]>; chunkAsset: SyncHook<[Chunk, string]>; assetPath: SyncWaterfallHook<[string, object, AssetInfo]>; needAdditionalPass: SyncBailHook<[], boolean>; childCompiler: SyncHook<[Compiler, string, number]>; log: SyncBailHook<[string, LogEntry], true>; processWarnings: SyncWaterfallHook<[WebpackError[]]>; processErrors: SyncWaterfallHook<[WebpackError[]]>; statsPreset: HookMap< SyncHook<[Partial<NormalizedStatsOptions>, CreateStatsOptionsContext]> >; statsNormalize: SyncHook< [Partial<NormalizedStatsOptions>, CreateStatsOptionsContext] >; statsFactory: SyncHook<[StatsFactory, NormalizedStatsOptions]>; statsPrinter: SyncHook<[StatsPrinter, NormalizedStatsOptions]>; get normalModuleLoader(): SyncHook<[object, NormalModule]>; }>; name?: string; startTime: any; endTime: any; compiler: Compiler; resolverFactory: ResolverFactory; inputFileSystem: InputFileSystem; fileSystemInfo: FileSystemInfo; valueCacheVersions: Map<string, string | Set<string>>; requestShortener: RequestShortener; compilerPath: string; logger: WebpackLogger; options: WebpackOptionsNormalized; outputOptions: OutputNormalized; bail: boolean; profile: boolean; params: CompilationParams; mainTemplate: MainTemplate; chunkTemplate: ChunkTemplate; runtimeTemplate: RuntimeTemplate; moduleTemplates: { javascript: ModuleTemplate }; moduleMemCaches?: Map<Module, WeakTupleMap<any, any>>; moduleMemCaches2?: Map<Module, WeakTupleMap<any, any>>; moduleGraph: ModuleGraph; chunkGraph: ChunkGraph; codeGenerationResults: CodeGenerationResults; processDependenciesQueue: AsyncQueue<Module, Module, Module>; addModuleQueue: AsyncQueue<Module, string, Module>; factorizeQueue: AsyncQueue< FactorizeModuleOptions, string, Module | ModuleFactoryResult >; buildQueue: AsyncQueue<Module, Module, Module>; rebuildQueue: AsyncQueue<Module, Module, Module>; /** * Modules in value are building during the build of Module in key. * Means value blocking key from finishing. * Needed to detect build cycles. */ creatingModuleDuringBuild: WeakMap<Module, Set<Module>>; entries: Map<string, EntryData>; globalEntry: EntryData; entrypoints: Map<string, Entrypoint>; asyncEntrypoints: Entrypoint[]; chunks: Set<Chunk>; chunkGroups: ChunkGroup[]; namedChunkGroups: Map<string, ChunkGroup>; namedChunks: Map<string, Chunk>; modules: Set<Module>; records: any; additionalChunkAssets: string[]; assets: CompilationAssets; assetsInfo: Map<string, AssetInfo>; errors: WebpackError[]; warnings: WebpackError[]; children: Compilation[]; logging: Map<string, LogEntry[]>; dependencyFactories: Map<DepConstructor, ModuleFactory>; dependencyTemplates: DependencyTemplates; childrenCounters: object; usedChunkIds: Set<string | number>; usedModuleIds: Set<number>; needAdditionalPass: boolean; builtModules: WeakSet<Module>; codeGeneratedModules: WeakSet<Module>; buildTimeExecutedModules: WeakSet<Module>; emittedAssets: Set<string>; comparedForEmitAssets: Set<string>; fileDependencies: LazySet<string>; contextDependencies: LazySet<string>; missingDependencies: LazySet<string>; buildDependencies: LazySet<string>; compilationDependencies: { add: (item?: any) => LazySet<string> }; getStats(): Stats; createStatsOptions( optionsOrPreset: string | StatsOptions, context?: CreateStatsOptionsContext ): NormalizedStatsOptions; createStatsFactory(options?: any): StatsFactory; createStatsPrinter(options?: any): StatsPrinter; getCache(name: string): CacheFacade; getLogger(name: string | (() => string)): WebpackLogger; addModule( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; /** * Fetches a module from a compilation by its identifier */ getModule(module: Module): Module; /** * Attempts to search for a module by its identifier */ findModule(identifier: string): undefined | Module; /** * Schedules a build of the module object */ buildModule( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; processModuleDependencies( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; processModuleDependenciesNonRecursive(module: Module): void; handleModuleCreation( __0: HandleModuleCreationOptions, callback: (err?: null | WebpackError, result?: Module) => void ): void; addModuleChain( context: string, dependency: Dependency, callback: (err?: null | WebpackError, result?: Module) => void ): void; addModuleTree( __0: { /** * context string path */ context: string; /** * dependency used to create Module chain */ dependency: Dependency; /** * additional context info for the root module */ contextInfo?: Partial<ModuleFactoryCreateDataContextInfo>; }, callback: (err?: null | WebpackError, result?: Module) => void ): void; addEntry( context: string, entry: Dependency, optionsOrName: string | EntryOptions, callback: (err?: null | WebpackError, result?: Module) => void ): void; addInclude( context: string, dependency: Dependency, options: EntryOptions, callback: (err?: null | WebpackError, result?: Module) => void ): void; rebuildModule( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; finish(callback?: any): void; unseal(): void; seal(callback: (err?: null | WebpackError) => void): void; reportDependencyErrorsAndWarnings( module: Module, blocks: DependenciesBlock[] ): boolean; codeGeneration(callback?: any): void; processRuntimeRequirements(__0?: { /** * the chunk graph */ chunkGraph?: ChunkGraph; /** * modules */ modules?: Iterable<Module>; /** * chunks */ chunks?: Iterable<Chunk>; /** * codeGenerationResults */ codeGenerationResults?: CodeGenerationResults; /** * chunkGraphEntries */ chunkGraphEntries?: Iterable<Chunk>; }): void; addRuntimeModule( chunk: Chunk, module: RuntimeModule, chunkGraph?: ChunkGraph ): void; /** * If `module` is passed, `loc` and `request` must also be passed. */ addChunkInGroup( groupOptions: string | ChunkGroupOptions, module?: Module, loc?: SyntheticDependencyLocation | RealDependencyLocation, request?: string ): ChunkGroup; addAsyncEntrypoint( options: EntryOptions, module: Module, loc: DependencyLocation, request: string ): Entrypoint; /** * This method first looks to see if a name is provided for a new chunk, * and first looks to see if any named chunks already exist and reuse that chunk instead. */ addChunk(name?: string): Chunk; assignDepth(module: Module): void; assignDepths(modules: Set<Module>): void; getDependencyReferencedExports( dependency: Dependency, runtime: RuntimeSpec ): (string[] | ReferencedExport)[]; removeReasonsOfDependencyBlock( module: Module, block: DependenciesBlockLike ): void; patchChunksAfterReasonRemoval(module: Module, chunk: Chunk): void; removeChunkFromDependencies(block: DependenciesBlock, chunk: Chunk): void; assignRuntimeIds(): void; sortItemsWithChunkIds(): void; summarizeDependencies(): void; createModuleHashes(): void; createHash(): { module: Module; hash: string; runtime: RuntimeSpec; runtimes: RuntimeSpec[]; }[]; fullHash?: string; hash?: string; emitAsset(file: string, source: Source, assetInfo?: AssetInfo): void; updateAsset( file: string, newSourceOrFunction: Source | ((arg0: Source) => Source), assetInfoUpdateOrFunction?: AssetInfo | ((arg0?: AssetInfo) => AssetInfo) ): void; renameAsset(file?: any, newFile?: any): void; deleteAsset(file: string): void; getAssets(): Readonly<Asset>[]; getAsset(name: string): undefined | Readonly<Asset>; clearAssets(): void; createModuleAssets(): void; getRenderManifest(options: RenderManifestOptions): RenderManifestEntry[]; createChunkAssets(callback: (err?: null | WebpackError) => void): void; getPath( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data?: PathData ): string; getPathWithInfo( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data?: PathData ): { path: string; info: AssetInfo }; getAssetPath( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data: PathData ): string; getAssetPathWithInfo( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data: PathData ): { path: string; info: AssetInfo }; getWarnings(): WebpackError[]; getErrors(): WebpackError[]; /** * This function allows you to run another instance of webpack inside of webpack however as * a child with different settings and configurations (if desired) applied. It copies all hooks, plugins * from parent (or top level compiler) and creates a child Compilation */ createChildCompiler( name: string, outputOptions?: OutputNormalized, plugins?: ( | ((this: Compiler, compiler: Compiler) => void) | WebpackPluginInstance )[] ): Compiler; executeModule( module: Module, options: ExecuteModuleOptions, callback: (err?: null | WebpackError, result?: ExecuteModuleResult) => void ): void; checkConstraints(): void; factorizeModule: { ( options: FactorizeModuleOptions & { factoryResult?: false }, callback: (err?: null | WebpackError, result?: Module) => void ): void; ( options: FactorizeModuleOptions & { factoryResult: true }, callback: ( err?: null | WebpackError, result?: ModuleFactoryResult ) => void ): void; }; /** * Add additional assets to the compilation. */ static PROCESS_ASSETS_STAGE_ADDITIONAL: number; /** * Basic preprocessing of assets. */ static PROCESS_ASSETS_STAGE_PRE_PROCESS: number; /** * Derive new assets from existing assets. * Existing assets should not be treated as complete. */ static PROCESS_ASSETS_STAGE_DERIVED: number; /** * Add additional sections to existing assets, like a banner or initialization code. */ static PROCESS_ASSETS_STAGE_ADDITIONS: number; /** * Optimize existing assets in a general way. */ static PROCESS_ASSETS_STAGE_OPTIMIZE: number; /** * Optimize the count of existing assets, e. g. by merging them. * Only assets of the same type should be merged. * For assets of different types see PROCESS_ASSETS_STAGE_OPTIMIZE_INLINE. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_COUNT: number; /** * Optimize the compatibility of existing assets, e. g. add polyfills or vendor-prefixes. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_COMPATIBILITY: number; /** * Optimize the size of existing assets, e. g. by minimizing or omitting whitespace. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_SIZE: number; /** * Add development tooling to assets, e. g. by extracting a SourceMap. */ static PROCESS_ASSETS_STAGE_DEV_TOOLING: number; /** * Optimize the count of existing assets, e. g. by inlining assets of into other assets. * Only assets of different types should be inlined. * For assets of the same type see PROCESS_ASSETS_STAGE_OPTIMIZE_COUNT. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_INLINE: number; /** * Summarize the list of existing assets * e. g. creating an assets manifest of Service Workers. */ static PROCESS_ASSETS_STAGE_SUMMARIZE: number; /** * Optimize the hashes of the assets, e. g. by generating real hashes of the asset content. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_HASH: number; /** * Optimize the transfer of existing assets, e. g. by preparing a compressed (gzip) file as separate asset. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_TRANSFER: number; /** * Analyse existing assets. */ static PROCESS_ASSETS_STAGE_ANALYSE: number; /** * Creating assets for reporting purposes. */ static PROCESS_ASSETS_STAGE_REPORT: number; }
3,427
( compiler: Compiler, callback: (err?: Error, api?: BackendApi) => void ) => void
interface BackendApi { dispose: (arg0?: Error) => void; module: (arg0: Module) => { client: string; data: string; active: boolean }; }
3,428
( compiler: Compiler, callback: (err?: Error, api?: BackendApi) => void ) => void
class Compiler { constructor(context: string, options?: WebpackOptionsNormalized); hooks: Readonly<{ initialize: SyncHook<[]>; shouldEmit: SyncBailHook<[Compilation], boolean>; done: AsyncSeriesHook<[Stats]>; afterDone: SyncHook<[Stats]>; additionalPass: AsyncSeriesHook<[]>; beforeRun: AsyncSeriesHook<[Compiler]>; run: AsyncSeriesHook<[Compiler]>; emit: AsyncSeriesHook<[Compilation]>; assetEmitted: AsyncSeriesHook<[string, AssetEmittedInfo]>; afterEmit: AsyncSeriesHook<[Compilation]>; thisCompilation: SyncHook<[Compilation, CompilationParams]>; compilation: SyncHook<[Compilation, CompilationParams]>; normalModuleFactory: SyncHook<[NormalModuleFactory]>; contextModuleFactory: SyncHook<[ContextModuleFactory]>; beforeCompile: AsyncSeriesHook<[CompilationParams]>; compile: SyncHook<[CompilationParams]>; make: AsyncParallelHook<[Compilation]>; finishMake: AsyncParallelHook<[Compilation]>; afterCompile: AsyncSeriesHook<[Compilation]>; readRecords: AsyncSeriesHook<[]>; emitRecords: AsyncSeriesHook<[]>; watchRun: AsyncSeriesHook<[Compiler]>; failed: SyncHook<[Error]>; invalid: SyncHook<[null | string, number]>; watchClose: SyncHook<[]>; shutdown: AsyncSeriesHook<[]>; infrastructureLog: SyncBailHook<[string, string, any[]], true>; environment: SyncHook<[]>; afterEnvironment: SyncHook<[]>; afterPlugins: SyncHook<[Compiler]>; afterResolvers: SyncHook<[Compiler]>; entryOption: SyncBailHook<[string, EntryNormalized], boolean>; }>; webpack: typeof exports; name?: string; parentCompilation?: Compilation; root: Compiler; outputPath: string; watching: Watching; outputFileSystem: OutputFileSystem; intermediateFileSystem: IntermediateFileSystem; inputFileSystem: InputFileSystem; watchFileSystem: WatchFileSystem; recordsInputPath: null | string; recordsOutputPath: null | string; records: object; managedPaths: Set<string | RegExp>; immutablePaths: Set<string | RegExp>; modifiedFiles: ReadonlySet<string>; removedFiles: ReadonlySet<string>; fileTimestamps: ReadonlyMap<string, null | FileSystemInfoEntry | "ignore">; contextTimestamps: ReadonlyMap<string, null | FileSystemInfoEntry | "ignore">; fsStartTime: number; resolverFactory: ResolverFactory; infrastructureLogger: any; options: WebpackOptionsNormalized; context: string; requestShortener: RequestShortener; cache: Cache; moduleMemCaches?: Map< Module, { buildInfo: object; references: WeakMap<Dependency, Module>; memCache: WeakTupleMap<any, any>; } >; compilerPath: string; running: boolean; idle: boolean; watchMode: boolean; getCache(name: string): CacheFacade; getInfrastructureLogger(name: string | (() => string)): WebpackLogger; watch(watchOptions: WatchOptions, handler: CallbackFunction<Stats>): Watching; run(callback: CallbackFunction<Stats>): void; runAsChild( callback: ( err?: null | Error, entries?: Chunk[], compilation?: Compilation ) => any ): void; purgeInputFileSystem(): void; emitAssets(compilation: Compilation, callback: CallbackFunction<void>): void; emitRecords(callback: CallbackFunction<void>): void; readRecords(callback: CallbackFunction<void>): void; createChildCompiler( compilation: Compilation, compilerName: string, compilerIndex: number, outputOptions?: OutputNormalized, plugins?: WebpackPluginInstance[] ): Compiler; isChild(): boolean; createCompilation(params?: any): Compilation; newCompilation(params: CompilationParams): Compilation; createNormalModuleFactory(): NormalModuleFactory; createContextModuleFactory(): ContextModuleFactory; newCompilationParams(): { normalModuleFactory: NormalModuleFactory; contextModuleFactory: ContextModuleFactory; }; compile(callback: CallbackFunction<Compilation>): void; close(callback: CallbackFunction<void>): void; }
3,429
(err?: Error, api?: BackendApi) => void
interface BackendApi { dispose: (arg0?: Error) => void; module: (arg0: Module) => { client: string; data: string; active: boolean }; }
3,430
(compiler: Compiler) => Promise<BackendApi>
class Compiler { constructor(context: string, options?: WebpackOptionsNormalized); hooks: Readonly<{ initialize: SyncHook<[]>; shouldEmit: SyncBailHook<[Compilation], boolean>; done: AsyncSeriesHook<[Stats]>; afterDone: SyncHook<[Stats]>; additionalPass: AsyncSeriesHook<[]>; beforeRun: AsyncSeriesHook<[Compiler]>; run: AsyncSeriesHook<[Compiler]>; emit: AsyncSeriesHook<[Compilation]>; assetEmitted: AsyncSeriesHook<[string, AssetEmittedInfo]>; afterEmit: AsyncSeriesHook<[Compilation]>; thisCompilation: SyncHook<[Compilation, CompilationParams]>; compilation: SyncHook<[Compilation, CompilationParams]>; normalModuleFactory: SyncHook<[NormalModuleFactory]>; contextModuleFactory: SyncHook<[ContextModuleFactory]>; beforeCompile: AsyncSeriesHook<[CompilationParams]>; compile: SyncHook<[CompilationParams]>; make: AsyncParallelHook<[Compilation]>; finishMake: AsyncParallelHook<[Compilation]>; afterCompile: AsyncSeriesHook<[Compilation]>; readRecords: AsyncSeriesHook<[]>; emitRecords: AsyncSeriesHook<[]>; watchRun: AsyncSeriesHook<[Compiler]>; failed: SyncHook<[Error]>; invalid: SyncHook<[null | string, number]>; watchClose: SyncHook<[]>; shutdown: AsyncSeriesHook<[]>; infrastructureLog: SyncBailHook<[string, string, any[]], true>; environment: SyncHook<[]>; afterEnvironment: SyncHook<[]>; afterPlugins: SyncHook<[Compiler]>; afterResolvers: SyncHook<[Compiler]>; entryOption: SyncBailHook<[string, EntryNormalized], boolean>; }>; webpack: typeof exports; name?: string; parentCompilation?: Compilation; root: Compiler; outputPath: string; watching: Watching; outputFileSystem: OutputFileSystem; intermediateFileSystem: IntermediateFileSystem; inputFileSystem: InputFileSystem; watchFileSystem: WatchFileSystem; recordsInputPath: null | string; recordsOutputPath: null | string; records: object; managedPaths: Set<string | RegExp>; immutablePaths: Set<string | RegExp>; modifiedFiles: ReadonlySet<string>; removedFiles: ReadonlySet<string>; fileTimestamps: ReadonlyMap<string, null | FileSystemInfoEntry | "ignore">; contextTimestamps: ReadonlyMap<string, null | FileSystemInfoEntry | "ignore">; fsStartTime: number; resolverFactory: ResolverFactory; infrastructureLogger: any; options: WebpackOptionsNormalized; context: string; requestShortener: RequestShortener; cache: Cache; moduleMemCaches?: Map< Module, { buildInfo: object; references: WeakMap<Dependency, Module>; memCache: WeakTupleMap<any, any>; } >; compilerPath: string; running: boolean; idle: boolean; watchMode: boolean; getCache(name: string): CacheFacade; getInfrastructureLogger(name: string | (() => string)): WebpackLogger; watch(watchOptions: WatchOptions, handler: CallbackFunction<Stats>): Watching; run(callback: CallbackFunction<Stats>): void; runAsChild( callback: ( err?: null | Error, entries?: Chunk[], compilation?: Compilation ) => any ): void; purgeInputFileSystem(): void; emitAssets(compilation: Compilation, callback: CallbackFunction<void>): void; emitRecords(callback: CallbackFunction<void>): void; readRecords(callback: CallbackFunction<void>): void; createChildCompiler( compilation: Compilation, compilerName: string, compilerIndex: number, outputOptions?: OutputNormalized, plugins?: WebpackPluginInstance[] ): Compiler; isChild(): boolean; createCompilation(params?: any): Compilation; newCompilation(params: CompilationParams): Compilation; createNormalModuleFactory(): NormalModuleFactory; createContextModuleFactory(): ContextModuleFactory; newCompilationParams(): { normalModuleFactory: NormalModuleFactory; contextModuleFactory: ContextModuleFactory; }; compile(callback: CallbackFunction<Compilation>): void; close(callback: CallbackFunction<void>): void; }
3,431
(module: Module) => boolean
interface Module { hot: webpack.Hot; }
3,432
(module: Module) => boolean
class Module extends DependenciesBlock { constructor(type: string, context?: string, layer?: string); type: string; context: null | string; layer: null | string; needId: boolean; debugId: number; resolveOptions: ResolveOptionsWebpackOptions; factoryMeta?: object; useSourceMap: boolean; useSimpleSourceMap: boolean; buildMeta: BuildMeta; buildInfo: Record<string, any>; presentationalDependencies?: Dependency[]; codeGenerationDependencies?: Dependency[]; id: string | number; get hash(): string; get renderedHash(): string; profile: null | ModuleProfile; index: number; index2: number; depth: number; issuer: null | Module; get usedExports(): null | boolean | SortableSet<string>; get optimizationBailout(): ( | string | ((requestShortener: RequestShortener) => string) )[]; get optional(): boolean; addChunk(chunk?: any): boolean; removeChunk(chunk?: any): void; isInChunk(chunk?: any): boolean; isEntryModule(): boolean; getChunks(): Chunk[]; getNumberOfChunks(): number; get chunksIterable(): Iterable<Chunk>; isProvided(exportName: string): null | boolean; get exportsArgument(): string; get moduleArgument(): string; getExportsType( moduleGraph: ModuleGraph, strict: boolean ): "namespace" | "default-only" | "default-with-named" | "dynamic"; addPresentationalDependency(presentationalDependency: Dependency): void; addCodeGenerationDependency(codeGenerationDependency: Dependency): void; addWarning(warning: WebpackError): void; getWarnings(): undefined | Iterable<WebpackError>; getNumberOfWarnings(): number; addError(error: WebpackError): void; getErrors(): undefined | Iterable<WebpackError>; getNumberOfErrors(): number; /** * removes all warnings and errors */ clearWarningsAndErrors(): void; isOptional(moduleGraph: ModuleGraph): boolean; isAccessibleInChunk( chunkGraph: ChunkGraph, chunk: Chunk, ignoreChunk?: Chunk ): boolean; isAccessibleInChunkGroup( chunkGraph: ChunkGraph, chunkGroup: ChunkGroup, ignoreChunk?: Chunk ): boolean; hasReasonForChunk( chunk: Chunk, moduleGraph: ModuleGraph, chunkGraph: ChunkGraph ): boolean; hasReasons(moduleGraph: ModuleGraph, runtime: RuntimeSpec): boolean; needBuild( context: NeedBuildContext, callback: (arg0?: null | WebpackError, arg1?: boolean) => void ): void; needRebuild( fileTimestamps: Map<string, null | number>, contextTimestamps: Map<string, null | number> ): boolean; invalidateBuild(): void; identifier(): string; readableIdentifier(requestShortener: RequestShortener): string; build( options: WebpackOptionsNormalized, compilation: Compilation, resolver: ResolverWithOptions, fs: InputFileSystem, callback: (arg0?: WebpackError) => void ): void; getSourceTypes(): Set<string>; source( dependencyTemplates: DependencyTemplates, runtimeTemplate: RuntimeTemplate, type?: string ): Source; size(type?: string): number; libIdent(options: LibIdentOptions): null | string; nameForCondition(): null | string; getConcatenationBailoutReason( context: ConcatenationBailoutReasonContext ): undefined | string; getSideEffectsConnectionState(moduleGraph: ModuleGraph): ConnectionState; codeGeneration(context: CodeGenerationContext): CodeGenerationResult; chunkCondition(chunk: Chunk, compilation: Compilation): boolean; hasChunkCondition(): boolean; /** * Assuming this module is in the cache. Update the (cached) module with * the fresh module from the factory. Usually updates internal references * and properties. */ updateCacheModule(module: Module): void; /** * Module should be unsafe cached. Get data that's needed for that. * This data will be passed to restoreFromUnsafeCache later. */ getUnsafeCacheData(): object; /** * Assuming this module is in the cache. Remove internal references to allow freeing some memory. */ cleanupForCache(): void; originalSource(): null | Source; addCacheDependencies( fileDependencies: LazySet<string>, contextDependencies: LazySet<string>, missingDependencies: LazySet<string>, buildDependencies: LazySet<string> ): void; get hasEqualsChunks(): any; get isUsed(): any; get errors(): any; get warnings(): any; used: any; }
3,433
constructor( name: LibraryName, target: string, umdNamedDefine: boolean, auxiliaryComment: AuxiliaryComment, exportProperty: LibraryExport )
type LibraryName = string | string[] | LibraryCustomUmdObject;
3,434
constructor( name: LibraryName, target: string, umdNamedDefine: boolean, auxiliaryComment: AuxiliaryComment, exportProperty: LibraryExport )
type LibraryName = string[] | string | LibraryCustomUmdObject;
3,435
constructor( name: LibraryName, target: string, umdNamedDefine: boolean, auxiliaryComment: AuxiliaryComment, exportProperty: LibraryExport )
type LibraryName = string[] | string | LibraryCustomUmdObject;
3,436
constructor( name: LibraryName, target: string, umdNamedDefine: boolean, auxiliaryComment: AuxiliaryComment, exportProperty: LibraryExport )
type LibraryName = string[] | string | LibraryCustomUmdObject;
3,437
constructor( name: LibraryName, target: string, umdNamedDefine: boolean, auxiliaryComment: AuxiliaryComment, exportProperty: LibraryExport )
type AuxiliaryComment = string | LibraryCustomUmdCommentObject;
3,438
constructor( name: LibraryName, target: string, umdNamedDefine: boolean, auxiliaryComment: AuxiliaryComment, exportProperty: LibraryExport )
type AuxiliaryComment = string | LibraryCustomUmdCommentObject;
3,439
constructor( name: LibraryName, target: string, umdNamedDefine: boolean, auxiliaryComment: AuxiliaryComment, exportProperty: LibraryExport )
type AuxiliaryComment = string | LibraryCustomUmdCommentObject;
3,440
constructor( name: LibraryName, target: string, umdNamedDefine: boolean, auxiliaryComment: AuxiliaryComment, exportProperty: LibraryExport )
type AuxiliaryComment = string | LibraryCustomUmdCommentObject;
3,441
constructor( name: LibraryName, target: string, umdNamedDefine: boolean, auxiliaryComment: AuxiliaryComment, exportProperty: LibraryExport )
type LibraryExport = string | string[];
3,442
constructor( name: LibraryName, target: string, umdNamedDefine: boolean, auxiliaryComment: AuxiliaryComment, exportProperty: LibraryExport )
type LibraryExport = string[] | string;
3,443
constructor( name: LibraryName, target: string, umdNamedDefine: boolean, auxiliaryComment: AuxiliaryComment, exportProperty: LibraryExport )
type LibraryExport = string[] | string;
3,444
constructor( name: LibraryName, target: string, umdNamedDefine: boolean, auxiliaryComment: AuxiliaryComment, exportProperty: LibraryExport )
type LibraryExport = string[] | string;
3,445
constructor(options?: LimitChunkCountPluginOptions)
interface LimitChunkCountPluginOptions { /** * Constant overhead for a chunk. */ chunkOverhead?: number; /** * Multiplicator for initial chunks. */ entryChunkMultiplicator?: number; /** * Limit the maximum number of chunks using a value greater greater than or equal to 1. */ maxChunks: number; }
3,446
constructor(options?: LimitChunkCountPluginOptions)
interface LimitChunkCountPluginOptions { /** * Constant overhead for a chunk. */ chunkOverhead?: number; /** * Multiplicator for initial chunks. */ entryChunkMultiplicator?: number; /** * Limit the maximum number of chunks using a value greater greater than or equal to 1. */ maxChunks: number; }
3,447
static getCompilationHooks( compilation: Compilation ): LoadScriptCompilationHooks
class Compilation { /** * Creates an instance of Compilation. */ constructor(compiler: Compiler, params: CompilationParams); hooks: Readonly<{ buildModule: SyncHook<[Module]>; rebuildModule: SyncHook<[Module]>; failedModule: SyncHook<[Module, WebpackError]>; succeedModule: SyncHook<[Module]>; stillValidModule: SyncHook<[Module]>; addEntry: SyncHook<[Dependency, EntryOptions]>; failedEntry: SyncHook<[Dependency, EntryOptions, Error]>; succeedEntry: SyncHook<[Dependency, EntryOptions, Module]>; dependencyReferencedExports: SyncWaterfallHook< [(string[] | ReferencedExport)[], Dependency, RuntimeSpec] >; executeModule: SyncHook<[ExecuteModuleArgument, ExecuteModuleContext]>; prepareModuleExecution: AsyncParallelHook< [ExecuteModuleArgument, ExecuteModuleContext] >; finishModules: AsyncSeriesHook<[Iterable<Module>]>; finishRebuildingModule: AsyncSeriesHook<[Module]>; unseal: SyncHook<[]>; seal: SyncHook<[]>; beforeChunks: SyncHook<[]>; afterChunks: SyncHook<[Iterable<Chunk>]>; optimizeDependencies: SyncBailHook<[Iterable<Module>], any>; afterOptimizeDependencies: SyncHook<[Iterable<Module>]>; optimize: SyncHook<[]>; optimizeModules: SyncBailHook<[Iterable<Module>], any>; afterOptimizeModules: SyncHook<[Iterable<Module>]>; optimizeChunks: SyncBailHook<[Iterable<Chunk>, ChunkGroup[]], any>; afterOptimizeChunks: SyncHook<[Iterable<Chunk>, ChunkGroup[]]>; optimizeTree: AsyncSeriesHook<[Iterable<Chunk>, Iterable<Module>]>; afterOptimizeTree: SyncHook<[Iterable<Chunk>, Iterable<Module>]>; optimizeChunkModules: AsyncSeriesBailHook< [Iterable<Chunk>, Iterable<Module>], any >; afterOptimizeChunkModules: SyncHook<[Iterable<Chunk>, Iterable<Module>]>; shouldRecord: SyncBailHook<[], boolean>; additionalChunkRuntimeRequirements: SyncHook< [Chunk, Set<string>, RuntimeRequirementsContext] >; runtimeRequirementInChunk: HookMap< SyncBailHook<[Chunk, Set<string>, RuntimeRequirementsContext], any> >; additionalModuleRuntimeRequirements: SyncHook< [Module, Set<string>, RuntimeRequirementsContext] >; runtimeRequirementInModule: HookMap< SyncBailHook<[Module, Set<string>, RuntimeRequirementsContext], any> >; additionalTreeRuntimeRequirements: SyncHook< [Chunk, Set<string>, RuntimeRequirementsContext] >; runtimeRequirementInTree: HookMap< SyncBailHook<[Chunk, Set<string>, RuntimeRequirementsContext], any> >; runtimeModule: SyncHook<[RuntimeModule, Chunk]>; reviveModules: SyncHook<[Iterable<Module>, any]>; beforeModuleIds: SyncHook<[Iterable<Module>]>; moduleIds: SyncHook<[Iterable<Module>]>; optimizeModuleIds: SyncHook<[Iterable<Module>]>; afterOptimizeModuleIds: SyncHook<[Iterable<Module>]>; reviveChunks: SyncHook<[Iterable<Chunk>, any]>; beforeChunkIds: SyncHook<[Iterable<Chunk>]>; chunkIds: SyncHook<[Iterable<Chunk>]>; optimizeChunkIds: SyncHook<[Iterable<Chunk>]>; afterOptimizeChunkIds: SyncHook<[Iterable<Chunk>]>; recordModules: SyncHook<[Iterable<Module>, any]>; recordChunks: SyncHook<[Iterable<Chunk>, any]>; optimizeCodeGeneration: SyncHook<[Iterable<Module>]>; beforeModuleHash: SyncHook<[]>; afterModuleHash: SyncHook<[]>; beforeCodeGeneration: SyncHook<[]>; afterCodeGeneration: SyncHook<[]>; beforeRuntimeRequirements: SyncHook<[]>; afterRuntimeRequirements: SyncHook<[]>; beforeHash: SyncHook<[]>; contentHash: SyncHook<[Chunk]>; afterHash: SyncHook<[]>; recordHash: SyncHook<[any]>; record: SyncHook<[Compilation, any]>; beforeModuleAssets: SyncHook<[]>; shouldGenerateChunkAssets: SyncBailHook<[], boolean>; beforeChunkAssets: SyncHook<[]>; additionalChunkAssets: FakeHook< Pick< AsyncSeriesHook<[Set<Chunk>]>, "name" | "tap" | "tapAsync" | "tapPromise" > >; additionalAssets: FakeHook< Pick<AsyncSeriesHook<[]>, "name" | "tap" | "tapAsync" | "tapPromise"> >; optimizeChunkAssets: FakeHook< Pick< AsyncSeriesHook<[Set<Chunk>]>, "name" | "tap" | "tapAsync" | "tapPromise" > >; afterOptimizeChunkAssets: FakeHook< Pick< AsyncSeriesHook<[Set<Chunk>]>, "name" | "tap" | "tapAsync" | "tapPromise" > >; optimizeAssets: AsyncSeriesHook< [CompilationAssets], ProcessAssetsAdditionalOptions >; afterOptimizeAssets: SyncHook<[CompilationAssets]>; processAssets: AsyncSeriesHook< [CompilationAssets], ProcessAssetsAdditionalOptions >; afterProcessAssets: SyncHook<[CompilationAssets]>; processAdditionalAssets: AsyncSeriesHook<[CompilationAssets]>; needAdditionalSeal: SyncBailHook<[], boolean>; afterSeal: AsyncSeriesHook<[]>; renderManifest: SyncWaterfallHook< [RenderManifestEntry[], RenderManifestOptions] >; fullHash: SyncHook<[Hash]>; chunkHash: SyncHook<[Chunk, Hash, ChunkHashContext]>; moduleAsset: SyncHook<[Module, string]>; chunkAsset: SyncHook<[Chunk, string]>; assetPath: SyncWaterfallHook<[string, object, AssetInfo]>; needAdditionalPass: SyncBailHook<[], boolean>; childCompiler: SyncHook<[Compiler, string, number]>; log: SyncBailHook<[string, LogEntry], true>; processWarnings: SyncWaterfallHook<[WebpackError[]]>; processErrors: SyncWaterfallHook<[WebpackError[]]>; statsPreset: HookMap< SyncHook<[Partial<NormalizedStatsOptions>, CreateStatsOptionsContext]> >; statsNormalize: SyncHook< [Partial<NormalizedStatsOptions>, CreateStatsOptionsContext] >; statsFactory: SyncHook<[StatsFactory, NormalizedStatsOptions]>; statsPrinter: SyncHook<[StatsPrinter, NormalizedStatsOptions]>; get normalModuleLoader(): SyncHook<[object, NormalModule]>; }>; name?: string; startTime: any; endTime: any; compiler: Compiler; resolverFactory: ResolverFactory; inputFileSystem: InputFileSystem; fileSystemInfo: FileSystemInfo; valueCacheVersions: Map<string, string | Set<string>>; requestShortener: RequestShortener; compilerPath: string; logger: WebpackLogger; options: WebpackOptionsNormalized; outputOptions: OutputNormalized; bail: boolean; profile: boolean; params: CompilationParams; mainTemplate: MainTemplate; chunkTemplate: ChunkTemplate; runtimeTemplate: RuntimeTemplate; moduleTemplates: { javascript: ModuleTemplate }; moduleMemCaches?: Map<Module, WeakTupleMap<any, any>>; moduleMemCaches2?: Map<Module, WeakTupleMap<any, any>>; moduleGraph: ModuleGraph; chunkGraph: ChunkGraph; codeGenerationResults: CodeGenerationResults; processDependenciesQueue: AsyncQueue<Module, Module, Module>; addModuleQueue: AsyncQueue<Module, string, Module>; factorizeQueue: AsyncQueue< FactorizeModuleOptions, string, Module | ModuleFactoryResult >; buildQueue: AsyncQueue<Module, Module, Module>; rebuildQueue: AsyncQueue<Module, Module, Module>; /** * Modules in value are building during the build of Module in key. * Means value blocking key from finishing. * Needed to detect build cycles. */ creatingModuleDuringBuild: WeakMap<Module, Set<Module>>; entries: Map<string, EntryData>; globalEntry: EntryData; entrypoints: Map<string, Entrypoint>; asyncEntrypoints: Entrypoint[]; chunks: Set<Chunk>; chunkGroups: ChunkGroup[]; namedChunkGroups: Map<string, ChunkGroup>; namedChunks: Map<string, Chunk>; modules: Set<Module>; records: any; additionalChunkAssets: string[]; assets: CompilationAssets; assetsInfo: Map<string, AssetInfo>; errors: WebpackError[]; warnings: WebpackError[]; children: Compilation[]; logging: Map<string, LogEntry[]>; dependencyFactories: Map<DepConstructor, ModuleFactory>; dependencyTemplates: DependencyTemplates; childrenCounters: object; usedChunkIds: Set<string | number>; usedModuleIds: Set<number>; needAdditionalPass: boolean; builtModules: WeakSet<Module>; codeGeneratedModules: WeakSet<Module>; buildTimeExecutedModules: WeakSet<Module>; emittedAssets: Set<string>; comparedForEmitAssets: Set<string>; fileDependencies: LazySet<string>; contextDependencies: LazySet<string>; missingDependencies: LazySet<string>; buildDependencies: LazySet<string>; compilationDependencies: { add: (item?: any) => LazySet<string> }; getStats(): Stats; createStatsOptions( optionsOrPreset: string | StatsOptions, context?: CreateStatsOptionsContext ): NormalizedStatsOptions; createStatsFactory(options?: any): StatsFactory; createStatsPrinter(options?: any): StatsPrinter; getCache(name: string): CacheFacade; getLogger(name: string | (() => string)): WebpackLogger; addModule( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; /** * Fetches a module from a compilation by its identifier */ getModule(module: Module): Module; /** * Attempts to search for a module by its identifier */ findModule(identifier: string): undefined | Module; /** * Schedules a build of the module object */ buildModule( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; processModuleDependencies( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; processModuleDependenciesNonRecursive(module: Module): void; handleModuleCreation( __0: HandleModuleCreationOptions, callback: (err?: null | WebpackError, result?: Module) => void ): void; addModuleChain( context: string, dependency: Dependency, callback: (err?: null | WebpackError, result?: Module) => void ): void; addModuleTree( __0: { /** * context string path */ context: string; /** * dependency used to create Module chain */ dependency: Dependency; /** * additional context info for the root module */ contextInfo?: Partial<ModuleFactoryCreateDataContextInfo>; }, callback: (err?: null | WebpackError, result?: Module) => void ): void; addEntry( context: string, entry: Dependency, optionsOrName: string | EntryOptions, callback: (err?: null | WebpackError, result?: Module) => void ): void; addInclude( context: string, dependency: Dependency, options: EntryOptions, callback: (err?: null | WebpackError, result?: Module) => void ): void; rebuildModule( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; finish(callback?: any): void; unseal(): void; seal(callback: (err?: null | WebpackError) => void): void; reportDependencyErrorsAndWarnings( module: Module, blocks: DependenciesBlock[] ): boolean; codeGeneration(callback?: any): void; processRuntimeRequirements(__0?: { /** * the chunk graph */ chunkGraph?: ChunkGraph; /** * modules */ modules?: Iterable<Module>; /** * chunks */ chunks?: Iterable<Chunk>; /** * codeGenerationResults */ codeGenerationResults?: CodeGenerationResults; /** * chunkGraphEntries */ chunkGraphEntries?: Iterable<Chunk>; }): void; addRuntimeModule( chunk: Chunk, module: RuntimeModule, chunkGraph?: ChunkGraph ): void; /** * If `module` is passed, `loc` and `request` must also be passed. */ addChunkInGroup( groupOptions: string | ChunkGroupOptions, module?: Module, loc?: SyntheticDependencyLocation | RealDependencyLocation, request?: string ): ChunkGroup; addAsyncEntrypoint( options: EntryOptions, module: Module, loc: DependencyLocation, request: string ): Entrypoint; /** * This method first looks to see if a name is provided for a new chunk, * and first looks to see if any named chunks already exist and reuse that chunk instead. */ addChunk(name?: string): Chunk; assignDepth(module: Module): void; assignDepths(modules: Set<Module>): void; getDependencyReferencedExports( dependency: Dependency, runtime: RuntimeSpec ): (string[] | ReferencedExport)[]; removeReasonsOfDependencyBlock( module: Module, block: DependenciesBlockLike ): void; patchChunksAfterReasonRemoval(module: Module, chunk: Chunk): void; removeChunkFromDependencies(block: DependenciesBlock, chunk: Chunk): void; assignRuntimeIds(): void; sortItemsWithChunkIds(): void; summarizeDependencies(): void; createModuleHashes(): void; createHash(): { module: Module; hash: string; runtime: RuntimeSpec; runtimes: RuntimeSpec[]; }[]; fullHash?: string; hash?: string; emitAsset(file: string, source: Source, assetInfo?: AssetInfo): void; updateAsset( file: string, newSourceOrFunction: Source | ((arg0: Source) => Source), assetInfoUpdateOrFunction?: AssetInfo | ((arg0?: AssetInfo) => AssetInfo) ): void; renameAsset(file?: any, newFile?: any): void; deleteAsset(file: string): void; getAssets(): Readonly<Asset>[]; getAsset(name: string): undefined | Readonly<Asset>; clearAssets(): void; createModuleAssets(): void; getRenderManifest(options: RenderManifestOptions): RenderManifestEntry[]; createChunkAssets(callback: (err?: null | WebpackError) => void): void; getPath( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data?: PathData ): string; getPathWithInfo( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data?: PathData ): { path: string; info: AssetInfo }; getAssetPath( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data: PathData ): string; getAssetPathWithInfo( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data: PathData ): { path: string; info: AssetInfo }; getWarnings(): WebpackError[]; getErrors(): WebpackError[]; /** * This function allows you to run another instance of webpack inside of webpack however as * a child with different settings and configurations (if desired) applied. It copies all hooks, plugins * from parent (or top level compiler) and creates a child Compilation */ createChildCompiler( name: string, outputOptions?: OutputNormalized, plugins?: ( | ((this: Compiler, compiler: Compiler) => void) | WebpackPluginInstance )[] ): Compiler; executeModule( module: Module, options: ExecuteModuleOptions, callback: (err?: null | WebpackError, result?: ExecuteModuleResult) => void ): void; checkConstraints(): void; factorizeModule: { ( options: FactorizeModuleOptions & { factoryResult?: false }, callback: (err?: null | WebpackError, result?: Module) => void ): void; ( options: FactorizeModuleOptions & { factoryResult: true }, callback: ( err?: null | WebpackError, result?: ModuleFactoryResult ) => void ): void; }; /** * Add additional assets to the compilation. */ static PROCESS_ASSETS_STAGE_ADDITIONAL: number; /** * Basic preprocessing of assets. */ static PROCESS_ASSETS_STAGE_PRE_PROCESS: number; /** * Derive new assets from existing assets. * Existing assets should not be treated as complete. */ static PROCESS_ASSETS_STAGE_DERIVED: number; /** * Add additional sections to existing assets, like a banner or initialization code. */ static PROCESS_ASSETS_STAGE_ADDITIONS: number; /** * Optimize existing assets in a general way. */ static PROCESS_ASSETS_STAGE_OPTIMIZE: number; /** * Optimize the count of existing assets, e. g. by merging them. * Only assets of the same type should be merged. * For assets of different types see PROCESS_ASSETS_STAGE_OPTIMIZE_INLINE. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_COUNT: number; /** * Optimize the compatibility of existing assets, e. g. add polyfills or vendor-prefixes. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_COMPATIBILITY: number; /** * Optimize the size of existing assets, e. g. by minimizing or omitting whitespace. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_SIZE: number; /** * Add development tooling to assets, e. g. by extracting a SourceMap. */ static PROCESS_ASSETS_STAGE_DEV_TOOLING: number; /** * Optimize the count of existing assets, e. g. by inlining assets of into other assets. * Only assets of different types should be inlined. * For assets of the same type see PROCESS_ASSETS_STAGE_OPTIMIZE_COUNT. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_INLINE: number; /** * Summarize the list of existing assets * e. g. creating an assets manifest of Service Workers. */ static PROCESS_ASSETS_STAGE_SUMMARIZE: number; /** * Optimize the hashes of the assets, e. g. by generating real hashes of the asset content. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_HASH: number; /** * Optimize the transfer of existing assets, e. g. by preparing a compressed (gzip) file as separate asset. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_TRANSFER: number; /** * Analyse existing assets. */ static PROCESS_ASSETS_STAGE_ANALYSE: number; /** * Creating assets for reporting purposes. */ static PROCESS_ASSETS_STAGE_REPORT: number; }
3,448
constructor(options?: LoaderOptionsPluginOptions)
interface LoaderOptionsPluginOptions { [index: string]: any; /** * Whether loaders should be in debug mode or not. debug will be removed as of webpack 3. */ debug?: boolean; /** * Where loaders can be switched to minimize mode. */ minimize?: boolean; /** * A configuration object that can be used to configure older loaders. */ options?: { [index: string]: any; /** * The context that can be used to configure older loaders. */ context?: string; }; }
3,449
constructor(options?: LoaderOptionsPluginOptions)
interface LoaderOptionsPluginOptions { /** * Whether loaders should be in debug mode or not. debug will be removed as of webpack 3. */ debug?: boolean; /** * Where loaders can be switched to minimize mode. */ minimize?: boolean; /** * A configuration object that can be used to configure older loaders. */ options?: { /** * The context that can be used to configure older loaders. */ context?: string; [k: string]: any; }; [k: string]: any; }
3,450
constructor(options: MinChunkSizePluginOptions)
interface MinChunkSizePluginOptions { /** * Constant overhead for a chunk. */ chunkOverhead?: number; /** * Multiplicator for initial chunks. */ entryChunkMultiplicator?: number; /** * Minimum number of characters. */ minChunkSize: number; }
3,451
constructor(options: MinChunkSizePluginOptions)
interface MinChunkSizePluginOptions { /** * Constant overhead for a chunk. */ chunkOverhead?: number; /** * Multiplicator for initial chunks. */ entryChunkMultiplicator?: number; /** * Minimum number of characters. */ minChunkSize: number; }
3,452
getExportsType( moduleGraph: ModuleGraph, strict: boolean ): "namespace" | "default-only" | "default-with-named" | "dynamic"
class ModuleGraph { constructor(); setParents( dependency: Dependency, block: DependenciesBlock, module: Module, indexInBlock?: number ): void; getParentModule(dependency: Dependency): Module; getParentBlock(dependency: Dependency): DependenciesBlock; getParentBlockIndex(dependency: Dependency): number; setResolvedModule( originModule: Module, dependency: Dependency, module: Module ): void; updateModule(dependency: Dependency, module: Module): void; removeConnection(dependency: Dependency): void; addExplanation(dependency: Dependency, explanation: string): void; cloneModuleAttributes(sourceModule: Module, targetModule: Module): void; removeModuleAttributes(module: Module): void; removeAllModuleAttributes(): void; moveModuleConnections( oldModule: Module, newModule: Module, filterConnection: (arg0: ModuleGraphConnection) => boolean ): void; copyOutgoingModuleConnections( oldModule: Module, newModule: Module, filterConnection: (arg0: ModuleGraphConnection) => boolean ): void; addExtraReason(module: Module, explanation: string): void; getResolvedModule(dependency: Dependency): Module; getConnection(dependency: Dependency): undefined | ModuleGraphConnection; getModule(dependency: Dependency): Module; getOrigin(dependency: Dependency): Module; getResolvedOrigin(dependency: Dependency): Module; getIncomingConnections(module: Module): Iterable<ModuleGraphConnection>; getOutgoingConnections(module: Module): Iterable<ModuleGraphConnection>; getIncomingConnectionsByOriginModule( module: Module ): Map<undefined | Module, ReadonlyArray<ModuleGraphConnection>>; getOutgoingConnectionsByModule( module: Module ): undefined | Map<undefined | Module, ReadonlyArray<ModuleGraphConnection>>; getProfile(module: Module): null | ModuleProfile; setProfile(module: Module, profile: null | ModuleProfile): void; getIssuer(module: Module): null | Module; setIssuer(module: Module, issuer: null | Module): void; setIssuerIfUnset(module: Module, issuer: null | Module): void; getOptimizationBailout( module: Module ): (string | ((requestShortener: RequestShortener) => string))[]; getProvidedExports(module: Module): null | true | string[]; isExportProvided( module: Module, exportName: string | string[] ): null | boolean; getExportsInfo(module: Module): ExportsInfo; getExportInfo(module: Module, exportName: string): ExportInfo; getReadOnlyExportInfo(module: Module, exportName: string): ExportInfo; getUsedExports( module: Module, runtime: RuntimeSpec ): null | boolean | SortableSet<string>; getPreOrderIndex(module: Module): number; getPostOrderIndex(module: Module): number; setPreOrderIndex(module: Module, index: number): void; setPreOrderIndexIfUnset(module: Module, index: number): boolean; setPostOrderIndex(module: Module, index: number): void; setPostOrderIndexIfUnset(module: Module, index: number): boolean; getDepth(module: Module): number; setDepth(module: Module, depth: number): void; setDepthIfLower(module: Module, depth: number): boolean; isAsync(module: Module): boolean; setAsync(module: Module): void; getMeta(thing?: any): Object; getMetaIfExisting(thing?: any): Object; freeze(cacheStage?: string): void; unfreeze(): void; cached<T extends any[], V>( fn: (moduleGraph: ModuleGraph, ...args: T) => V, ...args: T ): V; setModuleMemCaches( moduleMemCaches: Map<Module, WeakTupleMap<any, any>> ): void; dependencyCacheProvide(dependency: Dependency, ...args: any[]): any; static getModuleGraphForModule( module: Module, deprecateMessage: string, deprecationCode: string ): ModuleGraph; static setModuleGraphForModule( module: Module, moduleGraph: ModuleGraph ): void; static clearModuleGraphForModule(module: Module): void; static ModuleGraphConnection: typeof ModuleGraphConnection; }
3,453
addPresentationalDependency(presentationalDependency: Dependency): void
class Dependency { constructor(); weak: boolean; optional: boolean; get type(): string; get category(): string; loc: DependencyLocation; setLoc( startLine?: any, startColumn?: any, endLine?: any, endColumn?: any ): void; getContext(): undefined | string; getResourceIdentifier(): null | string; couldAffectReferencingModule(): boolean | typeof TRANSITIVE; /** * Returns the referenced module and export */ getReference(moduleGraph: ModuleGraph): never; /** * Returns list of exports referenced by this dependency */ getReferencedExports( moduleGraph: ModuleGraph, runtime: RuntimeSpec ): (string[] | ReferencedExport)[]; getCondition( moduleGraph: ModuleGraph ): | null | false | ((arg0: ModuleGraphConnection, arg1: RuntimeSpec) => ConnectionState); /** * Returns the exported names */ getExports(moduleGraph: ModuleGraph): undefined | ExportsSpec; /** * Returns warnings */ getWarnings(moduleGraph: ModuleGraph): WebpackError[]; /** * Returns errors */ getErrors(moduleGraph: ModuleGraph): WebpackError[]; /** * Update the hash */ updateHash(hash: Hash, context: UpdateHashContextDependency): void; /** * implement this method to allow the occurrence order plugin to count correctly */ getNumberOfIdOccurrences(): number; getModuleEvaluationSideEffectsState( moduleGraph: ModuleGraph ): ConnectionState; createIgnoredModule(context: string): Module; serialize(__0: { write: any }): void; deserialize(__0: { read: any }): void; module: any; get disconnect(): any; static NO_EXPORTS_REFERENCED: string[][]; static EXPORTS_OBJECT_REFERENCED: string[][]; static TRANSITIVE: typeof TRANSITIVE; }
3,454
addCodeGenerationDependency(codeGenerationDependency: Dependency): void
class Dependency { constructor(); weak: boolean; optional: boolean; get type(): string; get category(): string; loc: DependencyLocation; setLoc( startLine?: any, startColumn?: any, endLine?: any, endColumn?: any ): void; getContext(): undefined | string; getResourceIdentifier(): null | string; couldAffectReferencingModule(): boolean | typeof TRANSITIVE; /** * Returns the referenced module and export */ getReference(moduleGraph: ModuleGraph): never; /** * Returns list of exports referenced by this dependency */ getReferencedExports( moduleGraph: ModuleGraph, runtime: RuntimeSpec ): (string[] | ReferencedExport)[]; getCondition( moduleGraph: ModuleGraph ): | null | false | ((arg0: ModuleGraphConnection, arg1: RuntimeSpec) => ConnectionState); /** * Returns the exported names */ getExports(moduleGraph: ModuleGraph): undefined | ExportsSpec; /** * Returns warnings */ getWarnings(moduleGraph: ModuleGraph): WebpackError[]; /** * Returns errors */ getErrors(moduleGraph: ModuleGraph): WebpackError[]; /** * Update the hash */ updateHash(hash: Hash, context: UpdateHashContextDependency): void; /** * implement this method to allow the occurrence order plugin to count correctly */ getNumberOfIdOccurrences(): number; getModuleEvaluationSideEffectsState( moduleGraph: ModuleGraph ): ConnectionState; createIgnoredModule(context: string): Module; serialize(__0: { write: any }): void; deserialize(__0: { read: any }): void; module: any; get disconnect(): any; static NO_EXPORTS_REFERENCED: string[][]; static EXPORTS_OBJECT_REFERENCED: string[][]; static TRANSITIVE: typeof TRANSITIVE; }
3,455
addWarning(warning: WebpackError): void
class WebpackError extends Error { /** * Creates an instance of WebpackError. */ constructor(message?: string); details: any; module: Module; loc: DependencyLocation; hideStack: boolean; chunk: Chunk; file: string; serialize(__0: { write: any }): void; deserialize(__0: { read: any }): void; /** * Create .stack property on a target object */ static captureStackTrace( targetObject: object, constructorOpt?: Function ): void; /** * Optional override for formatting stack traces */ static prepareStackTrace?: ( err: Error, stackTraces: NodeJS.CallSite[] ) => any; static stackTraceLimit: number; }
3,456
addError(error: WebpackError): void
class WebpackError extends Error { /** * Creates an instance of WebpackError. */ constructor(message?: string); details: any; module: Module; loc: DependencyLocation; hideStack: boolean; chunk: Chunk; file: string; serialize(__0: { write: any }): void; deserialize(__0: { read: any }): void; /** * Create .stack property on a target object */ static captureStackTrace( targetObject: object, constructorOpt?: Function ): void; /** * Optional override for formatting stack traces */ static prepareStackTrace?: ( err: Error, stackTraces: NodeJS.CallSite[] ) => any; static stackTraceLimit: number; }
3,457
isOptional(moduleGraph: ModuleGraph): boolean
class ModuleGraph { constructor(); setParents( dependency: Dependency, block: DependenciesBlock, module: Module, indexInBlock?: number ): void; getParentModule(dependency: Dependency): Module; getParentBlock(dependency: Dependency): DependenciesBlock; getParentBlockIndex(dependency: Dependency): number; setResolvedModule( originModule: Module, dependency: Dependency, module: Module ): void; updateModule(dependency: Dependency, module: Module): void; removeConnection(dependency: Dependency): void; addExplanation(dependency: Dependency, explanation: string): void; cloneModuleAttributes(sourceModule: Module, targetModule: Module): void; removeModuleAttributes(module: Module): void; removeAllModuleAttributes(): void; moveModuleConnections( oldModule: Module, newModule: Module, filterConnection: (arg0: ModuleGraphConnection) => boolean ): void; copyOutgoingModuleConnections( oldModule: Module, newModule: Module, filterConnection: (arg0: ModuleGraphConnection) => boolean ): void; addExtraReason(module: Module, explanation: string): void; getResolvedModule(dependency: Dependency): Module; getConnection(dependency: Dependency): undefined | ModuleGraphConnection; getModule(dependency: Dependency): Module; getOrigin(dependency: Dependency): Module; getResolvedOrigin(dependency: Dependency): Module; getIncomingConnections(module: Module): Iterable<ModuleGraphConnection>; getOutgoingConnections(module: Module): Iterable<ModuleGraphConnection>; getIncomingConnectionsByOriginModule( module: Module ): Map<undefined | Module, ReadonlyArray<ModuleGraphConnection>>; getOutgoingConnectionsByModule( module: Module ): undefined | Map<undefined | Module, ReadonlyArray<ModuleGraphConnection>>; getProfile(module: Module): null | ModuleProfile; setProfile(module: Module, profile: null | ModuleProfile): void; getIssuer(module: Module): null | Module; setIssuer(module: Module, issuer: null | Module): void; setIssuerIfUnset(module: Module, issuer: null | Module): void; getOptimizationBailout( module: Module ): (string | ((requestShortener: RequestShortener) => string))[]; getProvidedExports(module: Module): null | true | string[]; isExportProvided( module: Module, exportName: string | string[] ): null | boolean; getExportsInfo(module: Module): ExportsInfo; getExportInfo(module: Module, exportName: string): ExportInfo; getReadOnlyExportInfo(module: Module, exportName: string): ExportInfo; getUsedExports( module: Module, runtime: RuntimeSpec ): null | boolean | SortableSet<string>; getPreOrderIndex(module: Module): number; getPostOrderIndex(module: Module): number; setPreOrderIndex(module: Module, index: number): void; setPreOrderIndexIfUnset(module: Module, index: number): boolean; setPostOrderIndex(module: Module, index: number): void; setPostOrderIndexIfUnset(module: Module, index: number): boolean; getDepth(module: Module): number; setDepth(module: Module, depth: number): void; setDepthIfLower(module: Module, depth: number): boolean; isAsync(module: Module): boolean; setAsync(module: Module): void; getMeta(thing?: any): Object; getMetaIfExisting(thing?: any): Object; freeze(cacheStage?: string): void; unfreeze(): void; cached<T extends any[], V>( fn: (moduleGraph: ModuleGraph, ...args: T) => V, ...args: T ): V; setModuleMemCaches( moduleMemCaches: Map<Module, WeakTupleMap<any, any>> ): void; dependencyCacheProvide(dependency: Dependency, ...args: any[]): any; static getModuleGraphForModule( module: Module, deprecateMessage: string, deprecationCode: string ): ModuleGraph; static setModuleGraphForModule( module: Module, moduleGraph: ModuleGraph ): void; static clearModuleGraphForModule(module: Module): void; static ModuleGraphConnection: typeof ModuleGraphConnection; }
3,458
isAccessibleInChunk( chunkGraph: ChunkGraph, chunk: Chunk, ignoreChunk?: Chunk ): boolean
class Chunk { constructor(name?: string, backCompat?: boolean); id: null | string | number; ids: null | (string | number)[]; debugId: number; name: string; idNameHints: SortableSet<string>; preventIntegration: boolean; filenameTemplate: | null | string | ((arg0: PathData, arg1?: AssetInfo) => string); cssFilenameTemplate: | null | string | ((arg0: PathData, arg1?: AssetInfo) => string); runtime: RuntimeSpec; files: Set<string>; auxiliaryFiles: Set<string>; rendered: boolean; hash?: string; contentHash: Record<string, string>; renderedHash?: string; chunkReason?: string; extraAsync: boolean; get entryModule(): Module; hasEntryModule(): boolean; addModule(module: Module): boolean; removeModule(module: Module): void; getNumberOfModules(): number; get modulesIterable(): Iterable<Module>; compareTo(otherChunk: Chunk): 0 | 1 | -1; containsModule(module: Module): boolean; getModules(): Module[]; remove(): void; moveModule(module: Module, otherChunk: Chunk): void; integrate(otherChunk: Chunk): boolean; canBeIntegrated(otherChunk: Chunk): boolean; isEmpty(): boolean; modulesSize(): number; size(options?: ChunkSizeOptions): number; integratedSize(otherChunk: Chunk, options: ChunkSizeOptions): number; getChunkModuleMaps(filterFn: (m: Module) => boolean): ChunkModuleMaps; hasModuleInGraph( filterFn: (m: Module) => boolean, filterChunkFn?: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): boolean; getChunkMaps(realHash: boolean): ChunkMaps; hasRuntime(): boolean; canBeInitial(): boolean; isOnlyInitial(): boolean; getEntryOptions(): undefined | EntryOptions; addGroup(chunkGroup: ChunkGroup): void; removeGroup(chunkGroup: ChunkGroup): void; isInGroup(chunkGroup: ChunkGroup): boolean; getNumberOfGroups(): number; get groupsIterable(): Iterable<ChunkGroup>; disconnectFromGroups(): void; split(newChunk: Chunk): void; updateHash(hash: Hash, chunkGraph: ChunkGraph): void; getAllAsyncChunks(): Set<Chunk>; getAllInitialChunks(): Set<Chunk>; getAllReferencedChunks(): Set<Chunk>; getAllReferencedAsyncEntrypoints(): Set<Entrypoint>; hasAsyncChunks(): boolean; getChildIdsByOrders( chunkGraph: ChunkGraph, filterFn?: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): Record<string, (string | number)[]>; getChildrenOfTypeInOrder( chunkGraph: ChunkGraph, type: string ): { onChunks: Chunk[]; chunks: Set<Chunk> }[]; getChildIdsByOrdersMap( chunkGraph: ChunkGraph, includeDirectChildren?: boolean, filterFn?: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): Record<string | number, Record<string, (string | number)[]>>; }
3,459
isAccessibleInChunk( chunkGraph: ChunkGraph, chunk: Chunk, ignoreChunk?: Chunk ): boolean
class ChunkGraph { constructor(moduleGraph: ModuleGraph, hashFunction?: string | typeof Hash); moduleGraph: ModuleGraph; connectChunkAndModule(chunk: Chunk, module: Module): void; disconnectChunkAndModule(chunk: Chunk, module: Module): void; disconnectChunk(chunk: Chunk): void; attachModules(chunk: Chunk, modules: Iterable<Module>): void; attachRuntimeModules(chunk: Chunk, modules: Iterable<RuntimeModule>): void; attachFullHashModules(chunk: Chunk, modules: Iterable<RuntimeModule>): void; attachDependentHashModules( chunk: Chunk, modules: Iterable<RuntimeModule> ): void; replaceModule(oldModule: Module, newModule: Module): void; isModuleInChunk(module: Module, chunk: Chunk): boolean; isModuleInChunkGroup(module: Module, chunkGroup: ChunkGroup): boolean; isEntryModule(module: Module): boolean; getModuleChunksIterable(module: Module): Iterable<Chunk>; getOrderedModuleChunksIterable( module: Module, sortFn: (arg0: Chunk, arg1: Chunk) => 0 | 1 | -1 ): Iterable<Chunk>; getModuleChunks(module: Module): Chunk[]; getNumberOfModuleChunks(module: Module): number; getModuleRuntimes(module: Module): RuntimeSpecSet; getNumberOfChunkModules(chunk: Chunk): number; getNumberOfChunkFullHashModules(chunk: Chunk): number; getChunkModulesIterable(chunk: Chunk): Iterable<Module>; getChunkModulesIterableBySourceType( chunk: Chunk, sourceType: string ): undefined | Iterable<Module>; setChunkModuleSourceTypes( chunk: Chunk, module: Module, sourceTypes: Set<string> ): void; getChunkModuleSourceTypes(chunk: Chunk, module: Module): Set<string>; getModuleSourceTypes(module: Module): Set<string>; getOrderedChunkModulesIterable( chunk: Chunk, comparator: (arg0: Module, arg1: Module) => 0 | 1 | -1 ): Iterable<Module>; getOrderedChunkModulesIterableBySourceType( chunk: Chunk, sourceType: string, comparator: (arg0: Module, arg1: Module) => 0 | 1 | -1 ): undefined | Iterable<Module>; getChunkModules(chunk: Chunk): Module[]; getOrderedChunkModules( chunk: Chunk, comparator: (arg0: Module, arg1: Module) => 0 | 1 | -1 ): Module[]; getChunkModuleIdMap( chunk: Chunk, filterFn: (m: Module) => boolean, includeAllChunks?: boolean ): Record<string | number, (string | number)[]>; getChunkModuleRenderedHashMap( chunk: Chunk, filterFn: (m: Module) => boolean, hashLength?: number, includeAllChunks?: boolean ): Record<string | number, Record<string | number, string>>; getChunkConditionMap( chunk: Chunk, filterFn: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): Record<string | number, boolean>; hasModuleInGraph( chunk: Chunk, filterFn: (m: Module) => boolean, filterChunkFn?: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): boolean; compareChunks(chunkA: Chunk, chunkB: Chunk): 0 | 1 | -1; getChunkModulesSize(chunk: Chunk): number; getChunkModulesSizes(chunk: Chunk): Record<string, number>; getChunkRootModules(chunk: Chunk): Module[]; getChunkSize(chunk: Chunk, options?: ChunkSizeOptions): number; getIntegratedChunksSize( chunkA: Chunk, chunkB: Chunk, options?: ChunkSizeOptions ): number; canChunksBeIntegrated(chunkA: Chunk, chunkB: Chunk): boolean; integrateChunks(chunkA: Chunk, chunkB: Chunk): void; upgradeDependentToFullHashModules(chunk: Chunk): void; isEntryModuleInChunk(module: Module, chunk: Chunk): boolean; connectChunkAndEntryModule( chunk: Chunk, module: Module, entrypoint?: Entrypoint ): void; connectChunkAndRuntimeModule(chunk: Chunk, module: RuntimeModule): void; addFullHashModuleToChunk(chunk: Chunk, module: RuntimeModule): void; addDependentHashModuleToChunk(chunk: Chunk, module: RuntimeModule): void; disconnectChunkAndEntryModule(chunk: Chunk, module: Module): void; disconnectChunkAndRuntimeModule(chunk: Chunk, module: RuntimeModule): void; disconnectEntryModule(module: Module): void; disconnectEntries(chunk: Chunk): void; getNumberOfEntryModules(chunk: Chunk): number; getNumberOfRuntimeModules(chunk: Chunk): number; getChunkEntryModulesIterable(chunk: Chunk): Iterable<Module>; getChunkEntryDependentChunksIterable(chunk: Chunk): Iterable<Chunk>; hasChunkEntryDependentChunks(chunk: Chunk): boolean; getChunkRuntimeModulesIterable(chunk: Chunk): Iterable<RuntimeModule>; getChunkRuntimeModulesInOrder(chunk: Chunk): RuntimeModule[]; getChunkFullHashModulesIterable( chunk: Chunk ): undefined | Iterable<RuntimeModule>; getChunkFullHashModulesSet( chunk: Chunk ): undefined | ReadonlySet<RuntimeModule>; getChunkDependentHashModulesIterable( chunk: Chunk ): undefined | Iterable<RuntimeModule>; getChunkEntryModulesWithChunkGroupIterable( chunk: Chunk ): Iterable<[Module, undefined | Entrypoint]>; getBlockChunkGroup(depBlock: AsyncDependenciesBlock): ChunkGroup; connectBlockAndChunkGroup( depBlock: AsyncDependenciesBlock, chunkGroup: ChunkGroup ): void; disconnectChunkGroup(chunkGroup: ChunkGroup): void; getModuleId(module: Module): string | number; setModuleId(module: Module, id: string | number): void; getRuntimeId(runtime: string): string | number; setRuntimeId(runtime: string, id: string | number): void; hasModuleHashes(module: Module, runtime: RuntimeSpec): boolean; getModuleHash(module: Module, runtime: RuntimeSpec): string; getRenderedModuleHash(module: Module, runtime: RuntimeSpec): string; setModuleHashes( module: Module, runtime: RuntimeSpec, hash: string, renderedHash: string ): void; addModuleRuntimeRequirements( module: Module, runtime: RuntimeSpec, items: Set<string>, transferOwnership?: boolean ): void; addChunkRuntimeRequirements(chunk: Chunk, items: Set<string>): void; addTreeRuntimeRequirements(chunk: Chunk, items: Iterable<string>): void; getModuleRuntimeRequirements( module: Module, runtime: RuntimeSpec ): ReadonlySet<string>; getChunkRuntimeRequirements(chunk: Chunk): ReadonlySet<string>; getModuleGraphHash( module: Module, runtime: RuntimeSpec, withConnections?: boolean ): string; getModuleGraphHashBigInt( module: Module, runtime: RuntimeSpec, withConnections?: boolean ): bigint; getTreeRuntimeRequirements(chunk: Chunk): ReadonlySet<string>; static getChunkGraphForModule( module: Module, deprecateMessage: string, deprecationCode: string ): ChunkGraph; static setChunkGraphForModule(module: Module, chunkGraph: ChunkGraph): void; static clearChunkGraphForModule(module: Module): void; static getChunkGraphForChunk( chunk: Chunk, deprecateMessage: string, deprecationCode: string ): ChunkGraph; static setChunkGraphForChunk(chunk: Chunk, chunkGraph: ChunkGraph): void; static clearChunkGraphForChunk(chunk: Chunk): void; }
3,460
isAccessibleInChunkGroup( chunkGraph: ChunkGraph, chunkGroup: ChunkGroup, ignoreChunk?: Chunk ): boolean
class Chunk { constructor(name?: string, backCompat?: boolean); id: null | string | number; ids: null | (string | number)[]; debugId: number; name: string; idNameHints: SortableSet<string>; preventIntegration: boolean; filenameTemplate: | null | string | ((arg0: PathData, arg1?: AssetInfo) => string); cssFilenameTemplate: | null | string | ((arg0: PathData, arg1?: AssetInfo) => string); runtime: RuntimeSpec; files: Set<string>; auxiliaryFiles: Set<string>; rendered: boolean; hash?: string; contentHash: Record<string, string>; renderedHash?: string; chunkReason?: string; extraAsync: boolean; get entryModule(): Module; hasEntryModule(): boolean; addModule(module: Module): boolean; removeModule(module: Module): void; getNumberOfModules(): number; get modulesIterable(): Iterable<Module>; compareTo(otherChunk: Chunk): 0 | 1 | -1; containsModule(module: Module): boolean; getModules(): Module[]; remove(): void; moveModule(module: Module, otherChunk: Chunk): void; integrate(otherChunk: Chunk): boolean; canBeIntegrated(otherChunk: Chunk): boolean; isEmpty(): boolean; modulesSize(): number; size(options?: ChunkSizeOptions): number; integratedSize(otherChunk: Chunk, options: ChunkSizeOptions): number; getChunkModuleMaps(filterFn: (m: Module) => boolean): ChunkModuleMaps; hasModuleInGraph( filterFn: (m: Module) => boolean, filterChunkFn?: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): boolean; getChunkMaps(realHash: boolean): ChunkMaps; hasRuntime(): boolean; canBeInitial(): boolean; isOnlyInitial(): boolean; getEntryOptions(): undefined | EntryOptions; addGroup(chunkGroup: ChunkGroup): void; removeGroup(chunkGroup: ChunkGroup): void; isInGroup(chunkGroup: ChunkGroup): boolean; getNumberOfGroups(): number; get groupsIterable(): Iterable<ChunkGroup>; disconnectFromGroups(): void; split(newChunk: Chunk): void; updateHash(hash: Hash, chunkGraph: ChunkGraph): void; getAllAsyncChunks(): Set<Chunk>; getAllInitialChunks(): Set<Chunk>; getAllReferencedChunks(): Set<Chunk>; getAllReferencedAsyncEntrypoints(): Set<Entrypoint>; hasAsyncChunks(): boolean; getChildIdsByOrders( chunkGraph: ChunkGraph, filterFn?: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): Record<string, (string | number)[]>; getChildrenOfTypeInOrder( chunkGraph: ChunkGraph, type: string ): { onChunks: Chunk[]; chunks: Set<Chunk> }[]; getChildIdsByOrdersMap( chunkGraph: ChunkGraph, includeDirectChildren?: boolean, filterFn?: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): Record<string | number, Record<string, (string | number)[]>>; }
3,461
isAccessibleInChunkGroup( chunkGraph: ChunkGraph, chunkGroup: ChunkGroup, ignoreChunk?: Chunk ): boolean
class ChunkGraph { constructor(moduleGraph: ModuleGraph, hashFunction?: string | typeof Hash); moduleGraph: ModuleGraph; connectChunkAndModule(chunk: Chunk, module: Module): void; disconnectChunkAndModule(chunk: Chunk, module: Module): void; disconnectChunk(chunk: Chunk): void; attachModules(chunk: Chunk, modules: Iterable<Module>): void; attachRuntimeModules(chunk: Chunk, modules: Iterable<RuntimeModule>): void; attachFullHashModules(chunk: Chunk, modules: Iterable<RuntimeModule>): void; attachDependentHashModules( chunk: Chunk, modules: Iterable<RuntimeModule> ): void; replaceModule(oldModule: Module, newModule: Module): void; isModuleInChunk(module: Module, chunk: Chunk): boolean; isModuleInChunkGroup(module: Module, chunkGroup: ChunkGroup): boolean; isEntryModule(module: Module): boolean; getModuleChunksIterable(module: Module): Iterable<Chunk>; getOrderedModuleChunksIterable( module: Module, sortFn: (arg0: Chunk, arg1: Chunk) => 0 | 1 | -1 ): Iterable<Chunk>; getModuleChunks(module: Module): Chunk[]; getNumberOfModuleChunks(module: Module): number; getModuleRuntimes(module: Module): RuntimeSpecSet; getNumberOfChunkModules(chunk: Chunk): number; getNumberOfChunkFullHashModules(chunk: Chunk): number; getChunkModulesIterable(chunk: Chunk): Iterable<Module>; getChunkModulesIterableBySourceType( chunk: Chunk, sourceType: string ): undefined | Iterable<Module>; setChunkModuleSourceTypes( chunk: Chunk, module: Module, sourceTypes: Set<string> ): void; getChunkModuleSourceTypes(chunk: Chunk, module: Module): Set<string>; getModuleSourceTypes(module: Module): Set<string>; getOrderedChunkModulesIterable( chunk: Chunk, comparator: (arg0: Module, arg1: Module) => 0 | 1 | -1 ): Iterable<Module>; getOrderedChunkModulesIterableBySourceType( chunk: Chunk, sourceType: string, comparator: (arg0: Module, arg1: Module) => 0 | 1 | -1 ): undefined | Iterable<Module>; getChunkModules(chunk: Chunk): Module[]; getOrderedChunkModules( chunk: Chunk, comparator: (arg0: Module, arg1: Module) => 0 | 1 | -1 ): Module[]; getChunkModuleIdMap( chunk: Chunk, filterFn: (m: Module) => boolean, includeAllChunks?: boolean ): Record<string | number, (string | number)[]>; getChunkModuleRenderedHashMap( chunk: Chunk, filterFn: (m: Module) => boolean, hashLength?: number, includeAllChunks?: boolean ): Record<string | number, Record<string | number, string>>; getChunkConditionMap( chunk: Chunk, filterFn: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): Record<string | number, boolean>; hasModuleInGraph( chunk: Chunk, filterFn: (m: Module) => boolean, filterChunkFn?: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): boolean; compareChunks(chunkA: Chunk, chunkB: Chunk): 0 | 1 | -1; getChunkModulesSize(chunk: Chunk): number; getChunkModulesSizes(chunk: Chunk): Record<string, number>; getChunkRootModules(chunk: Chunk): Module[]; getChunkSize(chunk: Chunk, options?: ChunkSizeOptions): number; getIntegratedChunksSize( chunkA: Chunk, chunkB: Chunk, options?: ChunkSizeOptions ): number; canChunksBeIntegrated(chunkA: Chunk, chunkB: Chunk): boolean; integrateChunks(chunkA: Chunk, chunkB: Chunk): void; upgradeDependentToFullHashModules(chunk: Chunk): void; isEntryModuleInChunk(module: Module, chunk: Chunk): boolean; connectChunkAndEntryModule( chunk: Chunk, module: Module, entrypoint?: Entrypoint ): void; connectChunkAndRuntimeModule(chunk: Chunk, module: RuntimeModule): void; addFullHashModuleToChunk(chunk: Chunk, module: RuntimeModule): void; addDependentHashModuleToChunk(chunk: Chunk, module: RuntimeModule): void; disconnectChunkAndEntryModule(chunk: Chunk, module: Module): void; disconnectChunkAndRuntimeModule(chunk: Chunk, module: RuntimeModule): void; disconnectEntryModule(module: Module): void; disconnectEntries(chunk: Chunk): void; getNumberOfEntryModules(chunk: Chunk): number; getNumberOfRuntimeModules(chunk: Chunk): number; getChunkEntryModulesIterable(chunk: Chunk): Iterable<Module>; getChunkEntryDependentChunksIterable(chunk: Chunk): Iterable<Chunk>; hasChunkEntryDependentChunks(chunk: Chunk): boolean; getChunkRuntimeModulesIterable(chunk: Chunk): Iterable<RuntimeModule>; getChunkRuntimeModulesInOrder(chunk: Chunk): RuntimeModule[]; getChunkFullHashModulesIterable( chunk: Chunk ): undefined | Iterable<RuntimeModule>; getChunkFullHashModulesSet( chunk: Chunk ): undefined | ReadonlySet<RuntimeModule>; getChunkDependentHashModulesIterable( chunk: Chunk ): undefined | Iterable<RuntimeModule>; getChunkEntryModulesWithChunkGroupIterable( chunk: Chunk ): Iterable<[Module, undefined | Entrypoint]>; getBlockChunkGroup(depBlock: AsyncDependenciesBlock): ChunkGroup; connectBlockAndChunkGroup( depBlock: AsyncDependenciesBlock, chunkGroup: ChunkGroup ): void; disconnectChunkGroup(chunkGroup: ChunkGroup): void; getModuleId(module: Module): string | number; setModuleId(module: Module, id: string | number): void; getRuntimeId(runtime: string): string | number; setRuntimeId(runtime: string, id: string | number): void; hasModuleHashes(module: Module, runtime: RuntimeSpec): boolean; getModuleHash(module: Module, runtime: RuntimeSpec): string; getRenderedModuleHash(module: Module, runtime: RuntimeSpec): string; setModuleHashes( module: Module, runtime: RuntimeSpec, hash: string, renderedHash: string ): void; addModuleRuntimeRequirements( module: Module, runtime: RuntimeSpec, items: Set<string>, transferOwnership?: boolean ): void; addChunkRuntimeRequirements(chunk: Chunk, items: Set<string>): void; addTreeRuntimeRequirements(chunk: Chunk, items: Iterable<string>): void; getModuleRuntimeRequirements( module: Module, runtime: RuntimeSpec ): ReadonlySet<string>; getChunkRuntimeRequirements(chunk: Chunk): ReadonlySet<string>; getModuleGraphHash( module: Module, runtime: RuntimeSpec, withConnections?: boolean ): string; getModuleGraphHashBigInt( module: Module, runtime: RuntimeSpec, withConnections?: boolean ): bigint; getTreeRuntimeRequirements(chunk: Chunk): ReadonlySet<string>; static getChunkGraphForModule( module: Module, deprecateMessage: string, deprecationCode: string ): ChunkGraph; static setChunkGraphForModule(module: Module, chunkGraph: ChunkGraph): void; static clearChunkGraphForModule(module: Module): void; static getChunkGraphForChunk( chunk: Chunk, deprecateMessage: string, deprecationCode: string ): ChunkGraph; static setChunkGraphForChunk(chunk: Chunk, chunkGraph: ChunkGraph): void; static clearChunkGraphForChunk(chunk: Chunk): void; }
3,462
hasReasonForChunk( chunk: Chunk, moduleGraph: ModuleGraph, chunkGraph: ChunkGraph ): boolean
class ModuleGraph { constructor(); setParents( dependency: Dependency, block: DependenciesBlock, module: Module, indexInBlock?: number ): void; getParentModule(dependency: Dependency): Module; getParentBlock(dependency: Dependency): DependenciesBlock; getParentBlockIndex(dependency: Dependency): number; setResolvedModule( originModule: Module, dependency: Dependency, module: Module ): void; updateModule(dependency: Dependency, module: Module): void; removeConnection(dependency: Dependency): void; addExplanation(dependency: Dependency, explanation: string): void; cloneModuleAttributes(sourceModule: Module, targetModule: Module): void; removeModuleAttributes(module: Module): void; removeAllModuleAttributes(): void; moveModuleConnections( oldModule: Module, newModule: Module, filterConnection: (arg0: ModuleGraphConnection) => boolean ): void; copyOutgoingModuleConnections( oldModule: Module, newModule: Module, filterConnection: (arg0: ModuleGraphConnection) => boolean ): void; addExtraReason(module: Module, explanation: string): void; getResolvedModule(dependency: Dependency): Module; getConnection(dependency: Dependency): undefined | ModuleGraphConnection; getModule(dependency: Dependency): Module; getOrigin(dependency: Dependency): Module; getResolvedOrigin(dependency: Dependency): Module; getIncomingConnections(module: Module): Iterable<ModuleGraphConnection>; getOutgoingConnections(module: Module): Iterable<ModuleGraphConnection>; getIncomingConnectionsByOriginModule( module: Module ): Map<undefined | Module, ReadonlyArray<ModuleGraphConnection>>; getOutgoingConnectionsByModule( module: Module ): undefined | Map<undefined | Module, ReadonlyArray<ModuleGraphConnection>>; getProfile(module: Module): null | ModuleProfile; setProfile(module: Module, profile: null | ModuleProfile): void; getIssuer(module: Module): null | Module; setIssuer(module: Module, issuer: null | Module): void; setIssuerIfUnset(module: Module, issuer: null | Module): void; getOptimizationBailout( module: Module ): (string | ((requestShortener: RequestShortener) => string))[]; getProvidedExports(module: Module): null | true | string[]; isExportProvided( module: Module, exportName: string | string[] ): null | boolean; getExportsInfo(module: Module): ExportsInfo; getExportInfo(module: Module, exportName: string): ExportInfo; getReadOnlyExportInfo(module: Module, exportName: string): ExportInfo; getUsedExports( module: Module, runtime: RuntimeSpec ): null | boolean | SortableSet<string>; getPreOrderIndex(module: Module): number; getPostOrderIndex(module: Module): number; setPreOrderIndex(module: Module, index: number): void; setPreOrderIndexIfUnset(module: Module, index: number): boolean; setPostOrderIndex(module: Module, index: number): void; setPostOrderIndexIfUnset(module: Module, index: number): boolean; getDepth(module: Module): number; setDepth(module: Module, depth: number): void; setDepthIfLower(module: Module, depth: number): boolean; isAsync(module: Module): boolean; setAsync(module: Module): void; getMeta(thing?: any): Object; getMetaIfExisting(thing?: any): Object; freeze(cacheStage?: string): void; unfreeze(): void; cached<T extends any[], V>( fn: (moduleGraph: ModuleGraph, ...args: T) => V, ...args: T ): V; setModuleMemCaches( moduleMemCaches: Map<Module, WeakTupleMap<any, any>> ): void; dependencyCacheProvide(dependency: Dependency, ...args: any[]): any; static getModuleGraphForModule( module: Module, deprecateMessage: string, deprecationCode: string ): ModuleGraph; static setModuleGraphForModule( module: Module, moduleGraph: ModuleGraph ): void; static clearModuleGraphForModule(module: Module): void; static ModuleGraphConnection: typeof ModuleGraphConnection; }
3,463
hasReasonForChunk( chunk: Chunk, moduleGraph: ModuleGraph, chunkGraph: ChunkGraph ): boolean
class Chunk { constructor(name?: string, backCompat?: boolean); id: null | string | number; ids: null | (string | number)[]; debugId: number; name: string; idNameHints: SortableSet<string>; preventIntegration: boolean; filenameTemplate: | null | string | ((arg0: PathData, arg1?: AssetInfo) => string); cssFilenameTemplate: | null | string | ((arg0: PathData, arg1?: AssetInfo) => string); runtime: RuntimeSpec; files: Set<string>; auxiliaryFiles: Set<string>; rendered: boolean; hash?: string; contentHash: Record<string, string>; renderedHash?: string; chunkReason?: string; extraAsync: boolean; get entryModule(): Module; hasEntryModule(): boolean; addModule(module: Module): boolean; removeModule(module: Module): void; getNumberOfModules(): number; get modulesIterable(): Iterable<Module>; compareTo(otherChunk: Chunk): 0 | 1 | -1; containsModule(module: Module): boolean; getModules(): Module[]; remove(): void; moveModule(module: Module, otherChunk: Chunk): void; integrate(otherChunk: Chunk): boolean; canBeIntegrated(otherChunk: Chunk): boolean; isEmpty(): boolean; modulesSize(): number; size(options?: ChunkSizeOptions): number; integratedSize(otherChunk: Chunk, options: ChunkSizeOptions): number; getChunkModuleMaps(filterFn: (m: Module) => boolean): ChunkModuleMaps; hasModuleInGraph( filterFn: (m: Module) => boolean, filterChunkFn?: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): boolean; getChunkMaps(realHash: boolean): ChunkMaps; hasRuntime(): boolean; canBeInitial(): boolean; isOnlyInitial(): boolean; getEntryOptions(): undefined | EntryOptions; addGroup(chunkGroup: ChunkGroup): void; removeGroup(chunkGroup: ChunkGroup): void; isInGroup(chunkGroup: ChunkGroup): boolean; getNumberOfGroups(): number; get groupsIterable(): Iterable<ChunkGroup>; disconnectFromGroups(): void; split(newChunk: Chunk): void; updateHash(hash: Hash, chunkGraph: ChunkGraph): void; getAllAsyncChunks(): Set<Chunk>; getAllInitialChunks(): Set<Chunk>; getAllReferencedChunks(): Set<Chunk>; getAllReferencedAsyncEntrypoints(): Set<Entrypoint>; hasAsyncChunks(): boolean; getChildIdsByOrders( chunkGraph: ChunkGraph, filterFn?: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): Record<string, (string | number)[]>; getChildrenOfTypeInOrder( chunkGraph: ChunkGraph, type: string ): { onChunks: Chunk[]; chunks: Set<Chunk> }[]; getChildIdsByOrdersMap( chunkGraph: ChunkGraph, includeDirectChildren?: boolean, filterFn?: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): Record<string | number, Record<string, (string | number)[]>>; }
3,464
hasReasonForChunk( chunk: Chunk, moduleGraph: ModuleGraph, chunkGraph: ChunkGraph ): boolean
class ChunkGraph { constructor(moduleGraph: ModuleGraph, hashFunction?: string | typeof Hash); moduleGraph: ModuleGraph; connectChunkAndModule(chunk: Chunk, module: Module): void; disconnectChunkAndModule(chunk: Chunk, module: Module): void; disconnectChunk(chunk: Chunk): void; attachModules(chunk: Chunk, modules: Iterable<Module>): void; attachRuntimeModules(chunk: Chunk, modules: Iterable<RuntimeModule>): void; attachFullHashModules(chunk: Chunk, modules: Iterable<RuntimeModule>): void; attachDependentHashModules( chunk: Chunk, modules: Iterable<RuntimeModule> ): void; replaceModule(oldModule: Module, newModule: Module): void; isModuleInChunk(module: Module, chunk: Chunk): boolean; isModuleInChunkGroup(module: Module, chunkGroup: ChunkGroup): boolean; isEntryModule(module: Module): boolean; getModuleChunksIterable(module: Module): Iterable<Chunk>; getOrderedModuleChunksIterable( module: Module, sortFn: (arg0: Chunk, arg1: Chunk) => 0 | 1 | -1 ): Iterable<Chunk>; getModuleChunks(module: Module): Chunk[]; getNumberOfModuleChunks(module: Module): number; getModuleRuntimes(module: Module): RuntimeSpecSet; getNumberOfChunkModules(chunk: Chunk): number; getNumberOfChunkFullHashModules(chunk: Chunk): number; getChunkModulesIterable(chunk: Chunk): Iterable<Module>; getChunkModulesIterableBySourceType( chunk: Chunk, sourceType: string ): undefined | Iterable<Module>; setChunkModuleSourceTypes( chunk: Chunk, module: Module, sourceTypes: Set<string> ): void; getChunkModuleSourceTypes(chunk: Chunk, module: Module): Set<string>; getModuleSourceTypes(module: Module): Set<string>; getOrderedChunkModulesIterable( chunk: Chunk, comparator: (arg0: Module, arg1: Module) => 0 | 1 | -1 ): Iterable<Module>; getOrderedChunkModulesIterableBySourceType( chunk: Chunk, sourceType: string, comparator: (arg0: Module, arg1: Module) => 0 | 1 | -1 ): undefined | Iterable<Module>; getChunkModules(chunk: Chunk): Module[]; getOrderedChunkModules( chunk: Chunk, comparator: (arg0: Module, arg1: Module) => 0 | 1 | -1 ): Module[]; getChunkModuleIdMap( chunk: Chunk, filterFn: (m: Module) => boolean, includeAllChunks?: boolean ): Record<string | number, (string | number)[]>; getChunkModuleRenderedHashMap( chunk: Chunk, filterFn: (m: Module) => boolean, hashLength?: number, includeAllChunks?: boolean ): Record<string | number, Record<string | number, string>>; getChunkConditionMap( chunk: Chunk, filterFn: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): Record<string | number, boolean>; hasModuleInGraph( chunk: Chunk, filterFn: (m: Module) => boolean, filterChunkFn?: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): boolean; compareChunks(chunkA: Chunk, chunkB: Chunk): 0 | 1 | -1; getChunkModulesSize(chunk: Chunk): number; getChunkModulesSizes(chunk: Chunk): Record<string, number>; getChunkRootModules(chunk: Chunk): Module[]; getChunkSize(chunk: Chunk, options?: ChunkSizeOptions): number; getIntegratedChunksSize( chunkA: Chunk, chunkB: Chunk, options?: ChunkSizeOptions ): number; canChunksBeIntegrated(chunkA: Chunk, chunkB: Chunk): boolean; integrateChunks(chunkA: Chunk, chunkB: Chunk): void; upgradeDependentToFullHashModules(chunk: Chunk): void; isEntryModuleInChunk(module: Module, chunk: Chunk): boolean; connectChunkAndEntryModule( chunk: Chunk, module: Module, entrypoint?: Entrypoint ): void; connectChunkAndRuntimeModule(chunk: Chunk, module: RuntimeModule): void; addFullHashModuleToChunk(chunk: Chunk, module: RuntimeModule): void; addDependentHashModuleToChunk(chunk: Chunk, module: RuntimeModule): void; disconnectChunkAndEntryModule(chunk: Chunk, module: Module): void; disconnectChunkAndRuntimeModule(chunk: Chunk, module: RuntimeModule): void; disconnectEntryModule(module: Module): void; disconnectEntries(chunk: Chunk): void; getNumberOfEntryModules(chunk: Chunk): number; getNumberOfRuntimeModules(chunk: Chunk): number; getChunkEntryModulesIterable(chunk: Chunk): Iterable<Module>; getChunkEntryDependentChunksIterable(chunk: Chunk): Iterable<Chunk>; hasChunkEntryDependentChunks(chunk: Chunk): boolean; getChunkRuntimeModulesIterable(chunk: Chunk): Iterable<RuntimeModule>; getChunkRuntimeModulesInOrder(chunk: Chunk): RuntimeModule[]; getChunkFullHashModulesIterable( chunk: Chunk ): undefined | Iterable<RuntimeModule>; getChunkFullHashModulesSet( chunk: Chunk ): undefined | ReadonlySet<RuntimeModule>; getChunkDependentHashModulesIterable( chunk: Chunk ): undefined | Iterable<RuntimeModule>; getChunkEntryModulesWithChunkGroupIterable( chunk: Chunk ): Iterable<[Module, undefined | Entrypoint]>; getBlockChunkGroup(depBlock: AsyncDependenciesBlock): ChunkGroup; connectBlockAndChunkGroup( depBlock: AsyncDependenciesBlock, chunkGroup: ChunkGroup ): void; disconnectChunkGroup(chunkGroup: ChunkGroup): void; getModuleId(module: Module): string | number; setModuleId(module: Module, id: string | number): void; getRuntimeId(runtime: string): string | number; setRuntimeId(runtime: string, id: string | number): void; hasModuleHashes(module: Module, runtime: RuntimeSpec): boolean; getModuleHash(module: Module, runtime: RuntimeSpec): string; getRenderedModuleHash(module: Module, runtime: RuntimeSpec): string; setModuleHashes( module: Module, runtime: RuntimeSpec, hash: string, renderedHash: string ): void; addModuleRuntimeRequirements( module: Module, runtime: RuntimeSpec, items: Set<string>, transferOwnership?: boolean ): void; addChunkRuntimeRequirements(chunk: Chunk, items: Set<string>): void; addTreeRuntimeRequirements(chunk: Chunk, items: Iterable<string>): void; getModuleRuntimeRequirements( module: Module, runtime: RuntimeSpec ): ReadonlySet<string>; getChunkRuntimeRequirements(chunk: Chunk): ReadonlySet<string>; getModuleGraphHash( module: Module, runtime: RuntimeSpec, withConnections?: boolean ): string; getModuleGraphHashBigInt( module: Module, runtime: RuntimeSpec, withConnections?: boolean ): bigint; getTreeRuntimeRequirements(chunk: Chunk): ReadonlySet<string>; static getChunkGraphForModule( module: Module, deprecateMessage: string, deprecationCode: string ): ChunkGraph; static setChunkGraphForModule(module: Module, chunkGraph: ChunkGraph): void; static clearChunkGraphForModule(module: Module): void; static getChunkGraphForChunk( chunk: Chunk, deprecateMessage: string, deprecationCode: string ): ChunkGraph; static setChunkGraphForChunk(chunk: Chunk, chunkGraph: ChunkGraph): void; static clearChunkGraphForChunk(chunk: Chunk): void; }
3,465
hasReasons(moduleGraph: ModuleGraph, runtime: RuntimeSpec): boolean
class ModuleGraph { constructor(); setParents( dependency: Dependency, block: DependenciesBlock, module: Module, indexInBlock?: number ): void; getParentModule(dependency: Dependency): Module; getParentBlock(dependency: Dependency): DependenciesBlock; getParentBlockIndex(dependency: Dependency): number; setResolvedModule( originModule: Module, dependency: Dependency, module: Module ): void; updateModule(dependency: Dependency, module: Module): void; removeConnection(dependency: Dependency): void; addExplanation(dependency: Dependency, explanation: string): void; cloneModuleAttributes(sourceModule: Module, targetModule: Module): void; removeModuleAttributes(module: Module): void; removeAllModuleAttributes(): void; moveModuleConnections( oldModule: Module, newModule: Module, filterConnection: (arg0: ModuleGraphConnection) => boolean ): void; copyOutgoingModuleConnections( oldModule: Module, newModule: Module, filterConnection: (arg0: ModuleGraphConnection) => boolean ): void; addExtraReason(module: Module, explanation: string): void; getResolvedModule(dependency: Dependency): Module; getConnection(dependency: Dependency): undefined | ModuleGraphConnection; getModule(dependency: Dependency): Module; getOrigin(dependency: Dependency): Module; getResolvedOrigin(dependency: Dependency): Module; getIncomingConnections(module: Module): Iterable<ModuleGraphConnection>; getOutgoingConnections(module: Module): Iterable<ModuleGraphConnection>; getIncomingConnectionsByOriginModule( module: Module ): Map<undefined | Module, ReadonlyArray<ModuleGraphConnection>>; getOutgoingConnectionsByModule( module: Module ): undefined | Map<undefined | Module, ReadonlyArray<ModuleGraphConnection>>; getProfile(module: Module): null | ModuleProfile; setProfile(module: Module, profile: null | ModuleProfile): void; getIssuer(module: Module): null | Module; setIssuer(module: Module, issuer: null | Module): void; setIssuerIfUnset(module: Module, issuer: null | Module): void; getOptimizationBailout( module: Module ): (string | ((requestShortener: RequestShortener) => string))[]; getProvidedExports(module: Module): null | true | string[]; isExportProvided( module: Module, exportName: string | string[] ): null | boolean; getExportsInfo(module: Module): ExportsInfo; getExportInfo(module: Module, exportName: string): ExportInfo; getReadOnlyExportInfo(module: Module, exportName: string): ExportInfo; getUsedExports( module: Module, runtime: RuntimeSpec ): null | boolean | SortableSet<string>; getPreOrderIndex(module: Module): number; getPostOrderIndex(module: Module): number; setPreOrderIndex(module: Module, index: number): void; setPreOrderIndexIfUnset(module: Module, index: number): boolean; setPostOrderIndex(module: Module, index: number): void; setPostOrderIndexIfUnset(module: Module, index: number): boolean; getDepth(module: Module): number; setDepth(module: Module, depth: number): void; setDepthIfLower(module: Module, depth: number): boolean; isAsync(module: Module): boolean; setAsync(module: Module): void; getMeta(thing?: any): Object; getMetaIfExisting(thing?: any): Object; freeze(cacheStage?: string): void; unfreeze(): void; cached<T extends any[], V>( fn: (moduleGraph: ModuleGraph, ...args: T) => V, ...args: T ): V; setModuleMemCaches( moduleMemCaches: Map<Module, WeakTupleMap<any, any>> ): void; dependencyCacheProvide(dependency: Dependency, ...args: any[]): any; static getModuleGraphForModule( module: Module, deprecateMessage: string, deprecationCode: string ): ModuleGraph; static setModuleGraphForModule( module: Module, moduleGraph: ModuleGraph ): void; static clearModuleGraphForModule(module: Module): void; static ModuleGraphConnection: typeof ModuleGraphConnection; }
3,466
hasReasons(moduleGraph: ModuleGraph, runtime: RuntimeSpec): boolean
type RuntimeSpec = undefined | string | SortableSet<string>;
3,467
needBuild( context: NeedBuildContext, callback: (arg0?: null | WebpackError, arg1?: boolean) => void ): void
interface NeedBuildContext { compilation: Compilation; fileSystemInfo: FileSystemInfo; valueCacheVersions: Map<string, string | Set<string>>; }
3,468
build( options: WebpackOptionsNormalized, compilation: Compilation, resolver: ResolverWithOptions, fs: InputFileSystem, callback: (arg0?: WebpackError) => void ): void
class WebpackError extends Error { /** * Creates an instance of WebpackError. */ constructor(message?: string); details: any; module: Module; loc: DependencyLocation; hideStack: boolean; chunk: Chunk; file: string; serialize(__0: { write: any }): void; deserialize(__0: { read: any }): void; /** * Create .stack property on a target object */ static captureStackTrace( targetObject: object, constructorOpt?: Function ): void; /** * Optional override for formatting stack traces */ static prepareStackTrace?: ( err: Error, stackTraces: NodeJS.CallSite[] ) => any; static stackTraceLimit: number; }
3,469
build( options: WebpackOptionsNormalized, compilation: Compilation, resolver: ResolverWithOptions, fs: InputFileSystem, callback: (arg0?: WebpackError) => void ): void
type ResolverWithOptions = Resolver & WithOptions;
3,470
build( options: WebpackOptionsNormalized, compilation: Compilation, resolver: ResolverWithOptions, fs: InputFileSystem, callback: (arg0?: WebpackError) => void ): void
interface InputFileSystem { readFile: ( arg0: string, arg1: (arg0?: null | NodeJS.ErrnoException, arg1?: string | Buffer) => void ) => void; readJson?: ( arg0: string, arg1: (arg0?: null | Error | NodeJS.ErrnoException, arg1?: any) => void ) => void; readlink: ( arg0: string, arg1: (arg0?: null | NodeJS.ErrnoException, arg1?: string | Buffer) => void ) => void; readdir: ( arg0: string, arg1: ( arg0?: null | NodeJS.ErrnoException, arg1?: (string | Buffer)[] | IDirent[] ) => void ) => void; stat: ( arg0: string, arg1: (arg0?: null | NodeJS.ErrnoException, arg1?: IStats) => void ) => void; lstat?: ( arg0: string, arg1: (arg0?: null | NodeJS.ErrnoException, arg1?: IStats) => void ) => void; realpath?: ( arg0: string, arg1: (arg0?: null | NodeJS.ErrnoException, arg1?: string | Buffer) => void ) => void; purge?: (arg0?: string) => void; join?: (arg0: string, arg1: string) => string; relative?: (arg0: string, arg1: string) => string; dirname?: (arg0: string) => string; }
3,471
build( options: WebpackOptionsNormalized, compilation: Compilation, resolver: ResolverWithOptions, fs: InputFileSystem, callback: (arg0?: WebpackError) => void ): void
interface WebpackOptionsNormalized { /** * Set the value of `require.amd` and `define.amd`. Or disable AMD support. */ amd?: false | { [index: string]: any }; /** * Report the first error as a hard error instead of tolerating it. */ bail?: boolean; /** * Cache generated modules and chunks to improve performance for multiple incremental builds. */ cache: CacheOptionsNormalized; /** * The base directory (absolute path!) for resolving the `entry` option. If `output.pathinfo` is set, the included pathinfo is shortened to this directory. */ context?: string; /** * References to other configurations to depend on. */ dependencies?: string[]; /** * Options for the webpack-dev-server. */ devServer?: DevServer; /** * A developer tool to enhance debugging (false | eval | [inline-|hidden-|eval-][nosources-][cheap-[module-]]source-map). */ devtool?: string | false; /** * The entry point(s) of the compilation. */ entry: EntryNormalized; /** * Enables/Disables experiments (experimental features with relax SemVer compatibility). */ experiments: ExperimentsNormalized; /** * Specify dependencies that shouldn't be resolved by webpack, but should become dependencies of the resulting bundle. The kind of the dependency depends on `output.libraryTarget`. */ externals: Externals; /** * Enable presets of externals for specific targets. */ externalsPresets: ExternalsPresets; /** * Specifies the default type of externals ('amd*', 'umd*', 'system' and 'jsonp' depend on output.libraryTarget set to the same value). */ externalsType?: | "import" | "var" | "module" | "assign" | "this" | "window" | "self" | "global" | "commonjs" | "commonjs2" | "commonjs-module" | "commonjs-static" | "amd" | "amd-require" | "umd" | "umd2" | "jsonp" | "system" | "promise" | "script" | "node-commonjs"; /** * Ignore specific warnings. */ ignoreWarnings?: (( warning: WebpackError, compilation: Compilation ) => boolean)[]; /** * Options for infrastructure level logging. */ infrastructureLogging: InfrastructureLogging; /** * Custom values available in the loader context. */ loader?: Loader; /** * Enable production optimizations or development hints. */ mode?: "none" | "development" | "production"; /** * Options affecting the normal modules (`NormalModuleFactory`). */ module: ModuleOptionsNormalized; /** * Name of the configuration. Used when loading multiple configurations. */ name?: string; /** * Include polyfills or mocks for various node stuff. */ node: NodeWebpackOptions; /** * Enables/Disables integrated optimizations. */ optimization: Optimization; /** * Normalized options affecting the output of the compilation. `output` options tell webpack how to write the compiled files to disk. */ output: OutputNormalized; /** * The number of parallel processed modules in the compilation. */ parallelism?: number; /** * Configuration for web performance recommendations. */ performance?: false | PerformanceOptions; /** * Add additional plugins to the compiler. */ plugins: ( | ((this: Compiler, compiler: Compiler) => void) | WebpackPluginInstance )[]; /** * Capture timing information for each module. */ profile?: boolean; /** * Store compiler state to a json file. */ recordsInputPath?: string | false; /** * Load compiler state from a json file. */ recordsOutputPath?: string | false; /** * Options for the resolver. */ resolve: ResolveOptionsWebpackOptions; /** * Options for the resolver when resolving loaders. */ resolveLoader: ResolveOptionsWebpackOptions; /** * Options affecting how file system snapshots are created and validated. */ snapshot: SnapshotOptions; /** * Stats options object or preset name. */ stats: StatsValue; /** * Environment to build for. An array of environments to build for all of them when possible. */ target?: string | false | string[]; /** * Enter watch mode, which rebuilds on file change. */ watch?: boolean; /** * Options for the watcher. */ watchOptions: WatchOptions; }
3,472
build( options: WebpackOptionsNormalized, compilation: Compilation, resolver: ResolverWithOptions, fs: InputFileSystem, callback: (arg0?: WebpackError) => void ): void
interface WebpackOptionsNormalized { /** * Set the value of `require.amd` and `define.amd`. Or disable AMD support. */ amd?: Amd; /** * Report the first error as a hard error instead of tolerating it. */ bail?: Bail; /** * Cache generated modules and chunks to improve performance for multiple incremental builds. */ cache: CacheOptionsNormalized; /** * The base directory (absolute path!) for resolving the `entry` option. If `output.pathinfo` is set, the included pathinfo is shortened to this directory. */ context?: Context; /** * References to other configurations to depend on. */ dependencies?: Dependencies; /** * Options for the webpack-dev-server. */ devServer?: DevServer; /** * A developer tool to enhance debugging (false | eval | [inline-|hidden-|eval-][nosources-][cheap-[module-]]source-map). */ devtool?: DevTool; /** * The entry point(s) of the compilation. */ entry: EntryNormalized; /** * Enables/Disables experiments (experimental features with relax SemVer compatibility). */ experiments: ExperimentsNormalized; /** * Specify dependencies that shouldn't be resolved by webpack, but should become dependencies of the resulting bundle. The kind of the dependency depends on `output.libraryTarget`. */ externals: Externals; /** * Enable presets of externals for specific targets. */ externalsPresets: ExternalsPresets; /** * Specifies the default type of externals ('amd*', 'umd*', 'system' and 'jsonp' depend on output.libraryTarget set to the same value). */ externalsType?: ExternalsType; /** * Ignore specific warnings. */ ignoreWarnings?: IgnoreWarningsNormalized; /** * Options for infrastructure level logging. */ infrastructureLogging: InfrastructureLogging; /** * Custom values available in the loader context. */ loader?: Loader; /** * Enable production optimizations or development hints. */ mode?: Mode; /** * Options affecting the normal modules (`NormalModuleFactory`). */ module: ModuleOptionsNormalized; /** * Name of the configuration. Used when loading multiple configurations. */ name?: Name; /** * Include polyfills or mocks for various node stuff. */ node: Node; /** * Enables/Disables integrated optimizations. */ optimization: Optimization; /** * Normalized options affecting the output of the compilation. `output` options tell webpack how to write the compiled files to disk. */ output: OutputNormalized; /** * The number of parallel processed modules in the compilation. */ parallelism?: Parallelism; /** * Configuration for web performance recommendations. */ performance?: Performance; /** * Add additional plugins to the compiler. */ plugins: Plugins; /** * Capture timing information for each module. */ profile?: Profile; /** * Store compiler state to a json file. */ recordsInputPath?: RecordsInputPath; /** * Load compiler state from a json file. */ recordsOutputPath?: RecordsOutputPath; /** * Options for the resolver. */ resolve: Resolve; /** * Options for the resolver when resolving loaders. */ resolveLoader: ResolveLoader; /** * Options affecting how file system snapshots are created and validated. */ snapshot: SnapshotOptions; /** * Stats options object or preset name. */ stats: StatsValue; /** * Environment to build for. An array of environments to build for all of them when possible. */ target?: Target; /** * Enter watch mode, which rebuilds on file change. */ watch?: Watch; /** * Options for the watcher. */ watchOptions: WatchOptions; }
3,473
build( options: WebpackOptionsNormalized, compilation: Compilation, resolver: ResolverWithOptions, fs: InputFileSystem, callback: (arg0?: WebpackError) => void ): void
class Compilation { /** * Creates an instance of Compilation. */ constructor(compiler: Compiler, params: CompilationParams); hooks: Readonly<{ buildModule: SyncHook<[Module]>; rebuildModule: SyncHook<[Module]>; failedModule: SyncHook<[Module, WebpackError]>; succeedModule: SyncHook<[Module]>; stillValidModule: SyncHook<[Module]>; addEntry: SyncHook<[Dependency, EntryOptions]>; failedEntry: SyncHook<[Dependency, EntryOptions, Error]>; succeedEntry: SyncHook<[Dependency, EntryOptions, Module]>; dependencyReferencedExports: SyncWaterfallHook< [(string[] | ReferencedExport)[], Dependency, RuntimeSpec] >; executeModule: SyncHook<[ExecuteModuleArgument, ExecuteModuleContext]>; prepareModuleExecution: AsyncParallelHook< [ExecuteModuleArgument, ExecuteModuleContext] >; finishModules: AsyncSeriesHook<[Iterable<Module>]>; finishRebuildingModule: AsyncSeriesHook<[Module]>; unseal: SyncHook<[]>; seal: SyncHook<[]>; beforeChunks: SyncHook<[]>; afterChunks: SyncHook<[Iterable<Chunk>]>; optimizeDependencies: SyncBailHook<[Iterable<Module>], any>; afterOptimizeDependencies: SyncHook<[Iterable<Module>]>; optimize: SyncHook<[]>; optimizeModules: SyncBailHook<[Iterable<Module>], any>; afterOptimizeModules: SyncHook<[Iterable<Module>]>; optimizeChunks: SyncBailHook<[Iterable<Chunk>, ChunkGroup[]], any>; afterOptimizeChunks: SyncHook<[Iterable<Chunk>, ChunkGroup[]]>; optimizeTree: AsyncSeriesHook<[Iterable<Chunk>, Iterable<Module>]>; afterOptimizeTree: SyncHook<[Iterable<Chunk>, Iterable<Module>]>; optimizeChunkModules: AsyncSeriesBailHook< [Iterable<Chunk>, Iterable<Module>], any >; afterOptimizeChunkModules: SyncHook<[Iterable<Chunk>, Iterable<Module>]>; shouldRecord: SyncBailHook<[], boolean>; additionalChunkRuntimeRequirements: SyncHook< [Chunk, Set<string>, RuntimeRequirementsContext] >; runtimeRequirementInChunk: HookMap< SyncBailHook<[Chunk, Set<string>, RuntimeRequirementsContext], any> >; additionalModuleRuntimeRequirements: SyncHook< [Module, Set<string>, RuntimeRequirementsContext] >; runtimeRequirementInModule: HookMap< SyncBailHook<[Module, Set<string>, RuntimeRequirementsContext], any> >; additionalTreeRuntimeRequirements: SyncHook< [Chunk, Set<string>, RuntimeRequirementsContext] >; runtimeRequirementInTree: HookMap< SyncBailHook<[Chunk, Set<string>, RuntimeRequirementsContext], any> >; runtimeModule: SyncHook<[RuntimeModule, Chunk]>; reviveModules: SyncHook<[Iterable<Module>, any]>; beforeModuleIds: SyncHook<[Iterable<Module>]>; moduleIds: SyncHook<[Iterable<Module>]>; optimizeModuleIds: SyncHook<[Iterable<Module>]>; afterOptimizeModuleIds: SyncHook<[Iterable<Module>]>; reviveChunks: SyncHook<[Iterable<Chunk>, any]>; beforeChunkIds: SyncHook<[Iterable<Chunk>]>; chunkIds: SyncHook<[Iterable<Chunk>]>; optimizeChunkIds: SyncHook<[Iterable<Chunk>]>; afterOptimizeChunkIds: SyncHook<[Iterable<Chunk>]>; recordModules: SyncHook<[Iterable<Module>, any]>; recordChunks: SyncHook<[Iterable<Chunk>, any]>; optimizeCodeGeneration: SyncHook<[Iterable<Module>]>; beforeModuleHash: SyncHook<[]>; afterModuleHash: SyncHook<[]>; beforeCodeGeneration: SyncHook<[]>; afterCodeGeneration: SyncHook<[]>; beforeRuntimeRequirements: SyncHook<[]>; afterRuntimeRequirements: SyncHook<[]>; beforeHash: SyncHook<[]>; contentHash: SyncHook<[Chunk]>; afterHash: SyncHook<[]>; recordHash: SyncHook<[any]>; record: SyncHook<[Compilation, any]>; beforeModuleAssets: SyncHook<[]>; shouldGenerateChunkAssets: SyncBailHook<[], boolean>; beforeChunkAssets: SyncHook<[]>; additionalChunkAssets: FakeHook< Pick< AsyncSeriesHook<[Set<Chunk>]>, "name" | "tap" | "tapAsync" | "tapPromise" > >; additionalAssets: FakeHook< Pick<AsyncSeriesHook<[]>, "name" | "tap" | "tapAsync" | "tapPromise"> >; optimizeChunkAssets: FakeHook< Pick< AsyncSeriesHook<[Set<Chunk>]>, "name" | "tap" | "tapAsync" | "tapPromise" > >; afterOptimizeChunkAssets: FakeHook< Pick< AsyncSeriesHook<[Set<Chunk>]>, "name" | "tap" | "tapAsync" | "tapPromise" > >; optimizeAssets: AsyncSeriesHook< [CompilationAssets], ProcessAssetsAdditionalOptions >; afterOptimizeAssets: SyncHook<[CompilationAssets]>; processAssets: AsyncSeriesHook< [CompilationAssets], ProcessAssetsAdditionalOptions >; afterProcessAssets: SyncHook<[CompilationAssets]>; processAdditionalAssets: AsyncSeriesHook<[CompilationAssets]>; needAdditionalSeal: SyncBailHook<[], boolean>; afterSeal: AsyncSeriesHook<[]>; renderManifest: SyncWaterfallHook< [RenderManifestEntry[], RenderManifestOptions] >; fullHash: SyncHook<[Hash]>; chunkHash: SyncHook<[Chunk, Hash, ChunkHashContext]>; moduleAsset: SyncHook<[Module, string]>; chunkAsset: SyncHook<[Chunk, string]>; assetPath: SyncWaterfallHook<[string, object, AssetInfo]>; needAdditionalPass: SyncBailHook<[], boolean>; childCompiler: SyncHook<[Compiler, string, number]>; log: SyncBailHook<[string, LogEntry], true>; processWarnings: SyncWaterfallHook<[WebpackError[]]>; processErrors: SyncWaterfallHook<[WebpackError[]]>; statsPreset: HookMap< SyncHook<[Partial<NormalizedStatsOptions>, CreateStatsOptionsContext]> >; statsNormalize: SyncHook< [Partial<NormalizedStatsOptions>, CreateStatsOptionsContext] >; statsFactory: SyncHook<[StatsFactory, NormalizedStatsOptions]>; statsPrinter: SyncHook<[StatsPrinter, NormalizedStatsOptions]>; get normalModuleLoader(): SyncHook<[object, NormalModule]>; }>; name?: string; startTime: any; endTime: any; compiler: Compiler; resolverFactory: ResolverFactory; inputFileSystem: InputFileSystem; fileSystemInfo: FileSystemInfo; valueCacheVersions: Map<string, string | Set<string>>; requestShortener: RequestShortener; compilerPath: string; logger: WebpackLogger; options: WebpackOptionsNormalized; outputOptions: OutputNormalized; bail: boolean; profile: boolean; params: CompilationParams; mainTemplate: MainTemplate; chunkTemplate: ChunkTemplate; runtimeTemplate: RuntimeTemplate; moduleTemplates: { javascript: ModuleTemplate }; moduleMemCaches?: Map<Module, WeakTupleMap<any, any>>; moduleMemCaches2?: Map<Module, WeakTupleMap<any, any>>; moduleGraph: ModuleGraph; chunkGraph: ChunkGraph; codeGenerationResults: CodeGenerationResults; processDependenciesQueue: AsyncQueue<Module, Module, Module>; addModuleQueue: AsyncQueue<Module, string, Module>; factorizeQueue: AsyncQueue< FactorizeModuleOptions, string, Module | ModuleFactoryResult >; buildQueue: AsyncQueue<Module, Module, Module>; rebuildQueue: AsyncQueue<Module, Module, Module>; /** * Modules in value are building during the build of Module in key. * Means value blocking key from finishing. * Needed to detect build cycles. */ creatingModuleDuringBuild: WeakMap<Module, Set<Module>>; entries: Map<string, EntryData>; globalEntry: EntryData; entrypoints: Map<string, Entrypoint>; asyncEntrypoints: Entrypoint[]; chunks: Set<Chunk>; chunkGroups: ChunkGroup[]; namedChunkGroups: Map<string, ChunkGroup>; namedChunks: Map<string, Chunk>; modules: Set<Module>; records: any; additionalChunkAssets: string[]; assets: CompilationAssets; assetsInfo: Map<string, AssetInfo>; errors: WebpackError[]; warnings: WebpackError[]; children: Compilation[]; logging: Map<string, LogEntry[]>; dependencyFactories: Map<DepConstructor, ModuleFactory>; dependencyTemplates: DependencyTemplates; childrenCounters: object; usedChunkIds: Set<string | number>; usedModuleIds: Set<number>; needAdditionalPass: boolean; builtModules: WeakSet<Module>; codeGeneratedModules: WeakSet<Module>; buildTimeExecutedModules: WeakSet<Module>; emittedAssets: Set<string>; comparedForEmitAssets: Set<string>; fileDependencies: LazySet<string>; contextDependencies: LazySet<string>; missingDependencies: LazySet<string>; buildDependencies: LazySet<string>; compilationDependencies: { add: (item?: any) => LazySet<string> }; getStats(): Stats; createStatsOptions( optionsOrPreset: string | StatsOptions, context?: CreateStatsOptionsContext ): NormalizedStatsOptions; createStatsFactory(options?: any): StatsFactory; createStatsPrinter(options?: any): StatsPrinter; getCache(name: string): CacheFacade; getLogger(name: string | (() => string)): WebpackLogger; addModule( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; /** * Fetches a module from a compilation by its identifier */ getModule(module: Module): Module; /** * Attempts to search for a module by its identifier */ findModule(identifier: string): undefined | Module; /** * Schedules a build of the module object */ buildModule( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; processModuleDependencies( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; processModuleDependenciesNonRecursive(module: Module): void; handleModuleCreation( __0: HandleModuleCreationOptions, callback: (err?: null | WebpackError, result?: Module) => void ): void; addModuleChain( context: string, dependency: Dependency, callback: (err?: null | WebpackError, result?: Module) => void ): void; addModuleTree( __0: { /** * context string path */ context: string; /** * dependency used to create Module chain */ dependency: Dependency; /** * additional context info for the root module */ contextInfo?: Partial<ModuleFactoryCreateDataContextInfo>; }, callback: (err?: null | WebpackError, result?: Module) => void ): void; addEntry( context: string, entry: Dependency, optionsOrName: string | EntryOptions, callback: (err?: null | WebpackError, result?: Module) => void ): void; addInclude( context: string, dependency: Dependency, options: EntryOptions, callback: (err?: null | WebpackError, result?: Module) => void ): void; rebuildModule( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; finish(callback?: any): void; unseal(): void; seal(callback: (err?: null | WebpackError) => void): void; reportDependencyErrorsAndWarnings( module: Module, blocks: DependenciesBlock[] ): boolean; codeGeneration(callback?: any): void; processRuntimeRequirements(__0?: { /** * the chunk graph */ chunkGraph?: ChunkGraph; /** * modules */ modules?: Iterable<Module>; /** * chunks */ chunks?: Iterable<Chunk>; /** * codeGenerationResults */ codeGenerationResults?: CodeGenerationResults; /** * chunkGraphEntries */ chunkGraphEntries?: Iterable<Chunk>; }): void; addRuntimeModule( chunk: Chunk, module: RuntimeModule, chunkGraph?: ChunkGraph ): void; /** * If `module` is passed, `loc` and `request` must also be passed. */ addChunkInGroup( groupOptions: string | ChunkGroupOptions, module?: Module, loc?: SyntheticDependencyLocation | RealDependencyLocation, request?: string ): ChunkGroup; addAsyncEntrypoint( options: EntryOptions, module: Module, loc: DependencyLocation, request: string ): Entrypoint; /** * This method first looks to see if a name is provided for a new chunk, * and first looks to see if any named chunks already exist and reuse that chunk instead. */ addChunk(name?: string): Chunk; assignDepth(module: Module): void; assignDepths(modules: Set<Module>): void; getDependencyReferencedExports( dependency: Dependency, runtime: RuntimeSpec ): (string[] | ReferencedExport)[]; removeReasonsOfDependencyBlock( module: Module, block: DependenciesBlockLike ): void; patchChunksAfterReasonRemoval(module: Module, chunk: Chunk): void; removeChunkFromDependencies(block: DependenciesBlock, chunk: Chunk): void; assignRuntimeIds(): void; sortItemsWithChunkIds(): void; summarizeDependencies(): void; createModuleHashes(): void; createHash(): { module: Module; hash: string; runtime: RuntimeSpec; runtimes: RuntimeSpec[]; }[]; fullHash?: string; hash?: string; emitAsset(file: string, source: Source, assetInfo?: AssetInfo): void; updateAsset( file: string, newSourceOrFunction: Source | ((arg0: Source) => Source), assetInfoUpdateOrFunction?: AssetInfo | ((arg0?: AssetInfo) => AssetInfo) ): void; renameAsset(file?: any, newFile?: any): void; deleteAsset(file: string): void; getAssets(): Readonly<Asset>[]; getAsset(name: string): undefined | Readonly<Asset>; clearAssets(): void; createModuleAssets(): void; getRenderManifest(options: RenderManifestOptions): RenderManifestEntry[]; createChunkAssets(callback: (err?: null | WebpackError) => void): void; getPath( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data?: PathData ): string; getPathWithInfo( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data?: PathData ): { path: string; info: AssetInfo }; getAssetPath( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data: PathData ): string; getAssetPathWithInfo( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data: PathData ): { path: string; info: AssetInfo }; getWarnings(): WebpackError[]; getErrors(): WebpackError[]; /** * This function allows you to run another instance of webpack inside of webpack however as * a child with different settings and configurations (if desired) applied. It copies all hooks, plugins * from parent (or top level compiler) and creates a child Compilation */ createChildCompiler( name: string, outputOptions?: OutputNormalized, plugins?: ( | ((this: Compiler, compiler: Compiler) => void) | WebpackPluginInstance )[] ): Compiler; executeModule( module: Module, options: ExecuteModuleOptions, callback: (err?: null | WebpackError, result?: ExecuteModuleResult) => void ): void; checkConstraints(): void; factorizeModule: { ( options: FactorizeModuleOptions & { factoryResult?: false }, callback: (err?: null | WebpackError, result?: Module) => void ): void; ( options: FactorizeModuleOptions & { factoryResult: true }, callback: ( err?: null | WebpackError, result?: ModuleFactoryResult ) => void ): void; }; /** * Add additional assets to the compilation. */ static PROCESS_ASSETS_STAGE_ADDITIONAL: number; /** * Basic preprocessing of assets. */ static PROCESS_ASSETS_STAGE_PRE_PROCESS: number; /** * Derive new assets from existing assets. * Existing assets should not be treated as complete. */ static PROCESS_ASSETS_STAGE_DERIVED: number; /** * Add additional sections to existing assets, like a banner or initialization code. */ static PROCESS_ASSETS_STAGE_ADDITIONS: number; /** * Optimize existing assets in a general way. */ static PROCESS_ASSETS_STAGE_OPTIMIZE: number; /** * Optimize the count of existing assets, e. g. by merging them. * Only assets of the same type should be merged. * For assets of different types see PROCESS_ASSETS_STAGE_OPTIMIZE_INLINE. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_COUNT: number; /** * Optimize the compatibility of existing assets, e. g. add polyfills or vendor-prefixes. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_COMPATIBILITY: number; /** * Optimize the size of existing assets, e. g. by minimizing or omitting whitespace. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_SIZE: number; /** * Add development tooling to assets, e. g. by extracting a SourceMap. */ static PROCESS_ASSETS_STAGE_DEV_TOOLING: number; /** * Optimize the count of existing assets, e. g. by inlining assets of into other assets. * Only assets of different types should be inlined. * For assets of the same type see PROCESS_ASSETS_STAGE_OPTIMIZE_COUNT. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_INLINE: number; /** * Summarize the list of existing assets * e. g. creating an assets manifest of Service Workers. */ static PROCESS_ASSETS_STAGE_SUMMARIZE: number; /** * Optimize the hashes of the assets, e. g. by generating real hashes of the asset content. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_HASH: number; /** * Optimize the transfer of existing assets, e. g. by preparing a compressed (gzip) file as separate asset. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_TRANSFER: number; /** * Analyse existing assets. */ static PROCESS_ASSETS_STAGE_ANALYSE: number; /** * Creating assets for reporting purposes. */ static PROCESS_ASSETS_STAGE_REPORT: number; }
3,474
(arg0?: WebpackError) => void
class WebpackError extends Error { /** * Creates an instance of WebpackError. */ constructor(message?: string); details: any; module: Module; loc: DependencyLocation; hideStack: boolean; chunk: Chunk; file: string; serialize(__0: { write: any }): void; deserialize(__0: { read: any }): void; /** * Create .stack property on a target object */ static captureStackTrace( targetObject: object, constructorOpt?: Function ): void; /** * Optional override for formatting stack traces */ static prepareStackTrace?: ( err: Error, stackTraces: NodeJS.CallSite[] ) => any; static stackTraceLimit: number; }
3,475
libIdent(options: LibIdentOptions): null | string
interface LibIdentOptions { /** * absolute context path to which lib ident is relative to */ context: string; /** * object for caching */ associatedObjectForCache?: Object; }
3,476
getConcatenationBailoutReason( context: ConcatenationBailoutReasonContext ): undefined | string
interface ConcatenationBailoutReasonContext { /** * the module graph */ moduleGraph: ModuleGraph; /** * the chunk graph */ chunkGraph: ChunkGraph; }
3,477
getSideEffectsConnectionState(moduleGraph: ModuleGraph): ConnectionState
class ModuleGraph { constructor(); setParents( dependency: Dependency, block: DependenciesBlock, module: Module, indexInBlock?: number ): void; getParentModule(dependency: Dependency): Module; getParentBlock(dependency: Dependency): DependenciesBlock; getParentBlockIndex(dependency: Dependency): number; setResolvedModule( originModule: Module, dependency: Dependency, module: Module ): void; updateModule(dependency: Dependency, module: Module): void; removeConnection(dependency: Dependency): void; addExplanation(dependency: Dependency, explanation: string): void; cloneModuleAttributes(sourceModule: Module, targetModule: Module): void; removeModuleAttributes(module: Module): void; removeAllModuleAttributes(): void; moveModuleConnections( oldModule: Module, newModule: Module, filterConnection: (arg0: ModuleGraphConnection) => boolean ): void; copyOutgoingModuleConnections( oldModule: Module, newModule: Module, filterConnection: (arg0: ModuleGraphConnection) => boolean ): void; addExtraReason(module: Module, explanation: string): void; getResolvedModule(dependency: Dependency): Module; getConnection(dependency: Dependency): undefined | ModuleGraphConnection; getModule(dependency: Dependency): Module; getOrigin(dependency: Dependency): Module; getResolvedOrigin(dependency: Dependency): Module; getIncomingConnections(module: Module): Iterable<ModuleGraphConnection>; getOutgoingConnections(module: Module): Iterable<ModuleGraphConnection>; getIncomingConnectionsByOriginModule( module: Module ): Map<undefined | Module, ReadonlyArray<ModuleGraphConnection>>; getOutgoingConnectionsByModule( module: Module ): undefined | Map<undefined | Module, ReadonlyArray<ModuleGraphConnection>>; getProfile(module: Module): null | ModuleProfile; setProfile(module: Module, profile: null | ModuleProfile): void; getIssuer(module: Module): null | Module; setIssuer(module: Module, issuer: null | Module): void; setIssuerIfUnset(module: Module, issuer: null | Module): void; getOptimizationBailout( module: Module ): (string | ((requestShortener: RequestShortener) => string))[]; getProvidedExports(module: Module): null | true | string[]; isExportProvided( module: Module, exportName: string | string[] ): null | boolean; getExportsInfo(module: Module): ExportsInfo; getExportInfo(module: Module, exportName: string): ExportInfo; getReadOnlyExportInfo(module: Module, exportName: string): ExportInfo; getUsedExports( module: Module, runtime: RuntimeSpec ): null | boolean | SortableSet<string>; getPreOrderIndex(module: Module): number; getPostOrderIndex(module: Module): number; setPreOrderIndex(module: Module, index: number): void; setPreOrderIndexIfUnset(module: Module, index: number): boolean; setPostOrderIndex(module: Module, index: number): void; setPostOrderIndexIfUnset(module: Module, index: number): boolean; getDepth(module: Module): number; setDepth(module: Module, depth: number): void; setDepthIfLower(module: Module, depth: number): boolean; isAsync(module: Module): boolean; setAsync(module: Module): void; getMeta(thing?: any): Object; getMetaIfExisting(thing?: any): Object; freeze(cacheStage?: string): void; unfreeze(): void; cached<T extends any[], V>( fn: (moduleGraph: ModuleGraph, ...args: T) => V, ...args: T ): V; setModuleMemCaches( moduleMemCaches: Map<Module, WeakTupleMap<any, any>> ): void; dependencyCacheProvide(dependency: Dependency, ...args: any[]): any; static getModuleGraphForModule( module: Module, deprecateMessage: string, deprecationCode: string ): ModuleGraph; static setModuleGraphForModule( module: Module, moduleGraph: ModuleGraph ): void; static clearModuleGraphForModule(module: Module): void; static ModuleGraphConnection: typeof ModuleGraphConnection; }
3,478
codeGeneration(context: CodeGenerationContext): CodeGenerationResult
interface CodeGenerationContext { /** * the dependency templates */ dependencyTemplates: DependencyTemplates; /** * the runtime template */ runtimeTemplate: RuntimeTemplate; /** * the module graph */ moduleGraph: ModuleGraph; /** * the chunk graph */ chunkGraph: ChunkGraph; /** * the runtimes code should be generated for */ runtime: RuntimeSpec; /** * when in concatenated module, information about other concatenated modules */ concatenationScope?: ConcatenationScope; /** * code generation results of other modules (need to have a codeGenerationDependency to use that) */ codeGenerationResults: CodeGenerationResults; /** * the compilation */ compilation?: Compilation; /** * source types */ sourceTypes?: ReadonlySet<string>; }
3,479
chunkCondition(chunk: Chunk, compilation: Compilation): boolean
class Compilation { /** * Creates an instance of Compilation. */ constructor(compiler: Compiler, params: CompilationParams); hooks: Readonly<{ buildModule: SyncHook<[Module]>; rebuildModule: SyncHook<[Module]>; failedModule: SyncHook<[Module, WebpackError]>; succeedModule: SyncHook<[Module]>; stillValidModule: SyncHook<[Module]>; addEntry: SyncHook<[Dependency, EntryOptions]>; failedEntry: SyncHook<[Dependency, EntryOptions, Error]>; succeedEntry: SyncHook<[Dependency, EntryOptions, Module]>; dependencyReferencedExports: SyncWaterfallHook< [(string[] | ReferencedExport)[], Dependency, RuntimeSpec] >; executeModule: SyncHook<[ExecuteModuleArgument, ExecuteModuleContext]>; prepareModuleExecution: AsyncParallelHook< [ExecuteModuleArgument, ExecuteModuleContext] >; finishModules: AsyncSeriesHook<[Iterable<Module>]>; finishRebuildingModule: AsyncSeriesHook<[Module]>; unseal: SyncHook<[]>; seal: SyncHook<[]>; beforeChunks: SyncHook<[]>; afterChunks: SyncHook<[Iterable<Chunk>]>; optimizeDependencies: SyncBailHook<[Iterable<Module>], any>; afterOptimizeDependencies: SyncHook<[Iterable<Module>]>; optimize: SyncHook<[]>; optimizeModules: SyncBailHook<[Iterable<Module>], any>; afterOptimizeModules: SyncHook<[Iterable<Module>]>; optimizeChunks: SyncBailHook<[Iterable<Chunk>, ChunkGroup[]], any>; afterOptimizeChunks: SyncHook<[Iterable<Chunk>, ChunkGroup[]]>; optimizeTree: AsyncSeriesHook<[Iterable<Chunk>, Iterable<Module>]>; afterOptimizeTree: SyncHook<[Iterable<Chunk>, Iterable<Module>]>; optimizeChunkModules: AsyncSeriesBailHook< [Iterable<Chunk>, Iterable<Module>], any >; afterOptimizeChunkModules: SyncHook<[Iterable<Chunk>, Iterable<Module>]>; shouldRecord: SyncBailHook<[], boolean>; additionalChunkRuntimeRequirements: SyncHook< [Chunk, Set<string>, RuntimeRequirementsContext] >; runtimeRequirementInChunk: HookMap< SyncBailHook<[Chunk, Set<string>, RuntimeRequirementsContext], any> >; additionalModuleRuntimeRequirements: SyncHook< [Module, Set<string>, RuntimeRequirementsContext] >; runtimeRequirementInModule: HookMap< SyncBailHook<[Module, Set<string>, RuntimeRequirementsContext], any> >; additionalTreeRuntimeRequirements: SyncHook< [Chunk, Set<string>, RuntimeRequirementsContext] >; runtimeRequirementInTree: HookMap< SyncBailHook<[Chunk, Set<string>, RuntimeRequirementsContext], any> >; runtimeModule: SyncHook<[RuntimeModule, Chunk]>; reviveModules: SyncHook<[Iterable<Module>, any]>; beforeModuleIds: SyncHook<[Iterable<Module>]>; moduleIds: SyncHook<[Iterable<Module>]>; optimizeModuleIds: SyncHook<[Iterable<Module>]>; afterOptimizeModuleIds: SyncHook<[Iterable<Module>]>; reviveChunks: SyncHook<[Iterable<Chunk>, any]>; beforeChunkIds: SyncHook<[Iterable<Chunk>]>; chunkIds: SyncHook<[Iterable<Chunk>]>; optimizeChunkIds: SyncHook<[Iterable<Chunk>]>; afterOptimizeChunkIds: SyncHook<[Iterable<Chunk>]>; recordModules: SyncHook<[Iterable<Module>, any]>; recordChunks: SyncHook<[Iterable<Chunk>, any]>; optimizeCodeGeneration: SyncHook<[Iterable<Module>]>; beforeModuleHash: SyncHook<[]>; afterModuleHash: SyncHook<[]>; beforeCodeGeneration: SyncHook<[]>; afterCodeGeneration: SyncHook<[]>; beforeRuntimeRequirements: SyncHook<[]>; afterRuntimeRequirements: SyncHook<[]>; beforeHash: SyncHook<[]>; contentHash: SyncHook<[Chunk]>; afterHash: SyncHook<[]>; recordHash: SyncHook<[any]>; record: SyncHook<[Compilation, any]>; beforeModuleAssets: SyncHook<[]>; shouldGenerateChunkAssets: SyncBailHook<[], boolean>; beforeChunkAssets: SyncHook<[]>; additionalChunkAssets: FakeHook< Pick< AsyncSeriesHook<[Set<Chunk>]>, "name" | "tap" | "tapAsync" | "tapPromise" > >; additionalAssets: FakeHook< Pick<AsyncSeriesHook<[]>, "name" | "tap" | "tapAsync" | "tapPromise"> >; optimizeChunkAssets: FakeHook< Pick< AsyncSeriesHook<[Set<Chunk>]>, "name" | "tap" | "tapAsync" | "tapPromise" > >; afterOptimizeChunkAssets: FakeHook< Pick< AsyncSeriesHook<[Set<Chunk>]>, "name" | "tap" | "tapAsync" | "tapPromise" > >; optimizeAssets: AsyncSeriesHook< [CompilationAssets], ProcessAssetsAdditionalOptions >; afterOptimizeAssets: SyncHook<[CompilationAssets]>; processAssets: AsyncSeriesHook< [CompilationAssets], ProcessAssetsAdditionalOptions >; afterProcessAssets: SyncHook<[CompilationAssets]>; processAdditionalAssets: AsyncSeriesHook<[CompilationAssets]>; needAdditionalSeal: SyncBailHook<[], boolean>; afterSeal: AsyncSeriesHook<[]>; renderManifest: SyncWaterfallHook< [RenderManifestEntry[], RenderManifestOptions] >; fullHash: SyncHook<[Hash]>; chunkHash: SyncHook<[Chunk, Hash, ChunkHashContext]>; moduleAsset: SyncHook<[Module, string]>; chunkAsset: SyncHook<[Chunk, string]>; assetPath: SyncWaterfallHook<[string, object, AssetInfo]>; needAdditionalPass: SyncBailHook<[], boolean>; childCompiler: SyncHook<[Compiler, string, number]>; log: SyncBailHook<[string, LogEntry], true>; processWarnings: SyncWaterfallHook<[WebpackError[]]>; processErrors: SyncWaterfallHook<[WebpackError[]]>; statsPreset: HookMap< SyncHook<[Partial<NormalizedStatsOptions>, CreateStatsOptionsContext]> >; statsNormalize: SyncHook< [Partial<NormalizedStatsOptions>, CreateStatsOptionsContext] >; statsFactory: SyncHook<[StatsFactory, NormalizedStatsOptions]>; statsPrinter: SyncHook<[StatsPrinter, NormalizedStatsOptions]>; get normalModuleLoader(): SyncHook<[object, NormalModule]>; }>; name?: string; startTime: any; endTime: any; compiler: Compiler; resolverFactory: ResolverFactory; inputFileSystem: InputFileSystem; fileSystemInfo: FileSystemInfo; valueCacheVersions: Map<string, string | Set<string>>; requestShortener: RequestShortener; compilerPath: string; logger: WebpackLogger; options: WebpackOptionsNormalized; outputOptions: OutputNormalized; bail: boolean; profile: boolean; params: CompilationParams; mainTemplate: MainTemplate; chunkTemplate: ChunkTemplate; runtimeTemplate: RuntimeTemplate; moduleTemplates: { javascript: ModuleTemplate }; moduleMemCaches?: Map<Module, WeakTupleMap<any, any>>; moduleMemCaches2?: Map<Module, WeakTupleMap<any, any>>; moduleGraph: ModuleGraph; chunkGraph: ChunkGraph; codeGenerationResults: CodeGenerationResults; processDependenciesQueue: AsyncQueue<Module, Module, Module>; addModuleQueue: AsyncQueue<Module, string, Module>; factorizeQueue: AsyncQueue< FactorizeModuleOptions, string, Module | ModuleFactoryResult >; buildQueue: AsyncQueue<Module, Module, Module>; rebuildQueue: AsyncQueue<Module, Module, Module>; /** * Modules in value are building during the build of Module in key. * Means value blocking key from finishing. * Needed to detect build cycles. */ creatingModuleDuringBuild: WeakMap<Module, Set<Module>>; entries: Map<string, EntryData>; globalEntry: EntryData; entrypoints: Map<string, Entrypoint>; asyncEntrypoints: Entrypoint[]; chunks: Set<Chunk>; chunkGroups: ChunkGroup[]; namedChunkGroups: Map<string, ChunkGroup>; namedChunks: Map<string, Chunk>; modules: Set<Module>; records: any; additionalChunkAssets: string[]; assets: CompilationAssets; assetsInfo: Map<string, AssetInfo>; errors: WebpackError[]; warnings: WebpackError[]; children: Compilation[]; logging: Map<string, LogEntry[]>; dependencyFactories: Map<DepConstructor, ModuleFactory>; dependencyTemplates: DependencyTemplates; childrenCounters: object; usedChunkIds: Set<string | number>; usedModuleIds: Set<number>; needAdditionalPass: boolean; builtModules: WeakSet<Module>; codeGeneratedModules: WeakSet<Module>; buildTimeExecutedModules: WeakSet<Module>; emittedAssets: Set<string>; comparedForEmitAssets: Set<string>; fileDependencies: LazySet<string>; contextDependencies: LazySet<string>; missingDependencies: LazySet<string>; buildDependencies: LazySet<string>; compilationDependencies: { add: (item?: any) => LazySet<string> }; getStats(): Stats; createStatsOptions( optionsOrPreset: string | StatsOptions, context?: CreateStatsOptionsContext ): NormalizedStatsOptions; createStatsFactory(options?: any): StatsFactory; createStatsPrinter(options?: any): StatsPrinter; getCache(name: string): CacheFacade; getLogger(name: string | (() => string)): WebpackLogger; addModule( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; /** * Fetches a module from a compilation by its identifier */ getModule(module: Module): Module; /** * Attempts to search for a module by its identifier */ findModule(identifier: string): undefined | Module; /** * Schedules a build of the module object */ buildModule( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; processModuleDependencies( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; processModuleDependenciesNonRecursive(module: Module): void; handleModuleCreation( __0: HandleModuleCreationOptions, callback: (err?: null | WebpackError, result?: Module) => void ): void; addModuleChain( context: string, dependency: Dependency, callback: (err?: null | WebpackError, result?: Module) => void ): void; addModuleTree( __0: { /** * context string path */ context: string; /** * dependency used to create Module chain */ dependency: Dependency; /** * additional context info for the root module */ contextInfo?: Partial<ModuleFactoryCreateDataContextInfo>; }, callback: (err?: null | WebpackError, result?: Module) => void ): void; addEntry( context: string, entry: Dependency, optionsOrName: string | EntryOptions, callback: (err?: null | WebpackError, result?: Module) => void ): void; addInclude( context: string, dependency: Dependency, options: EntryOptions, callback: (err?: null | WebpackError, result?: Module) => void ): void; rebuildModule( module: Module, callback: (err?: null | WebpackError, result?: Module) => void ): void; finish(callback?: any): void; unseal(): void; seal(callback: (err?: null | WebpackError) => void): void; reportDependencyErrorsAndWarnings( module: Module, blocks: DependenciesBlock[] ): boolean; codeGeneration(callback?: any): void; processRuntimeRequirements(__0?: { /** * the chunk graph */ chunkGraph?: ChunkGraph; /** * modules */ modules?: Iterable<Module>; /** * chunks */ chunks?: Iterable<Chunk>; /** * codeGenerationResults */ codeGenerationResults?: CodeGenerationResults; /** * chunkGraphEntries */ chunkGraphEntries?: Iterable<Chunk>; }): void; addRuntimeModule( chunk: Chunk, module: RuntimeModule, chunkGraph?: ChunkGraph ): void; /** * If `module` is passed, `loc` and `request` must also be passed. */ addChunkInGroup( groupOptions: string | ChunkGroupOptions, module?: Module, loc?: SyntheticDependencyLocation | RealDependencyLocation, request?: string ): ChunkGroup; addAsyncEntrypoint( options: EntryOptions, module: Module, loc: DependencyLocation, request: string ): Entrypoint; /** * This method first looks to see if a name is provided for a new chunk, * and first looks to see if any named chunks already exist and reuse that chunk instead. */ addChunk(name?: string): Chunk; assignDepth(module: Module): void; assignDepths(modules: Set<Module>): void; getDependencyReferencedExports( dependency: Dependency, runtime: RuntimeSpec ): (string[] | ReferencedExport)[]; removeReasonsOfDependencyBlock( module: Module, block: DependenciesBlockLike ): void; patchChunksAfterReasonRemoval(module: Module, chunk: Chunk): void; removeChunkFromDependencies(block: DependenciesBlock, chunk: Chunk): void; assignRuntimeIds(): void; sortItemsWithChunkIds(): void; summarizeDependencies(): void; createModuleHashes(): void; createHash(): { module: Module; hash: string; runtime: RuntimeSpec; runtimes: RuntimeSpec[]; }[]; fullHash?: string; hash?: string; emitAsset(file: string, source: Source, assetInfo?: AssetInfo): void; updateAsset( file: string, newSourceOrFunction: Source | ((arg0: Source) => Source), assetInfoUpdateOrFunction?: AssetInfo | ((arg0?: AssetInfo) => AssetInfo) ): void; renameAsset(file?: any, newFile?: any): void; deleteAsset(file: string): void; getAssets(): Readonly<Asset>[]; getAsset(name: string): undefined | Readonly<Asset>; clearAssets(): void; createModuleAssets(): void; getRenderManifest(options: RenderManifestOptions): RenderManifestEntry[]; createChunkAssets(callback: (err?: null | WebpackError) => void): void; getPath( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data?: PathData ): string; getPathWithInfo( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data?: PathData ): { path: string; info: AssetInfo }; getAssetPath( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data: PathData ): string; getAssetPathWithInfo( filename: string | ((arg0: PathData, arg1?: AssetInfo) => string), data: PathData ): { path: string; info: AssetInfo }; getWarnings(): WebpackError[]; getErrors(): WebpackError[]; /** * This function allows you to run another instance of webpack inside of webpack however as * a child with different settings and configurations (if desired) applied. It copies all hooks, plugins * from parent (or top level compiler) and creates a child Compilation */ createChildCompiler( name: string, outputOptions?: OutputNormalized, plugins?: ( | ((this: Compiler, compiler: Compiler) => void) | WebpackPluginInstance )[] ): Compiler; executeModule( module: Module, options: ExecuteModuleOptions, callback: (err?: null | WebpackError, result?: ExecuteModuleResult) => void ): void; checkConstraints(): void; factorizeModule: { ( options: FactorizeModuleOptions & { factoryResult?: false }, callback: (err?: null | WebpackError, result?: Module) => void ): void; ( options: FactorizeModuleOptions & { factoryResult: true }, callback: ( err?: null | WebpackError, result?: ModuleFactoryResult ) => void ): void; }; /** * Add additional assets to the compilation. */ static PROCESS_ASSETS_STAGE_ADDITIONAL: number; /** * Basic preprocessing of assets. */ static PROCESS_ASSETS_STAGE_PRE_PROCESS: number; /** * Derive new assets from existing assets. * Existing assets should not be treated as complete. */ static PROCESS_ASSETS_STAGE_DERIVED: number; /** * Add additional sections to existing assets, like a banner or initialization code. */ static PROCESS_ASSETS_STAGE_ADDITIONS: number; /** * Optimize existing assets in a general way. */ static PROCESS_ASSETS_STAGE_OPTIMIZE: number; /** * Optimize the count of existing assets, e. g. by merging them. * Only assets of the same type should be merged. * For assets of different types see PROCESS_ASSETS_STAGE_OPTIMIZE_INLINE. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_COUNT: number; /** * Optimize the compatibility of existing assets, e. g. add polyfills or vendor-prefixes. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_COMPATIBILITY: number; /** * Optimize the size of existing assets, e. g. by minimizing or omitting whitespace. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_SIZE: number; /** * Add development tooling to assets, e. g. by extracting a SourceMap. */ static PROCESS_ASSETS_STAGE_DEV_TOOLING: number; /** * Optimize the count of existing assets, e. g. by inlining assets of into other assets. * Only assets of different types should be inlined. * For assets of the same type see PROCESS_ASSETS_STAGE_OPTIMIZE_COUNT. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_INLINE: number; /** * Summarize the list of existing assets * e. g. creating an assets manifest of Service Workers. */ static PROCESS_ASSETS_STAGE_SUMMARIZE: number; /** * Optimize the hashes of the assets, e. g. by generating real hashes of the asset content. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_HASH: number; /** * Optimize the transfer of existing assets, e. g. by preparing a compressed (gzip) file as separate asset. */ static PROCESS_ASSETS_STAGE_OPTIMIZE_TRANSFER: number; /** * Analyse existing assets. */ static PROCESS_ASSETS_STAGE_ANALYSE: number; /** * Creating assets for reporting purposes. */ static PROCESS_ASSETS_STAGE_REPORT: number; }
3,480
chunkCondition(chunk: Chunk, compilation: Compilation): boolean
class Chunk { constructor(name?: string, backCompat?: boolean); id: null | string | number; ids: null | (string | number)[]; debugId: number; name: string; idNameHints: SortableSet<string>; preventIntegration: boolean; filenameTemplate: | null | string | ((arg0: PathData, arg1?: AssetInfo) => string); cssFilenameTemplate: | null | string | ((arg0: PathData, arg1?: AssetInfo) => string); runtime: RuntimeSpec; files: Set<string>; auxiliaryFiles: Set<string>; rendered: boolean; hash?: string; contentHash: Record<string, string>; renderedHash?: string; chunkReason?: string; extraAsync: boolean; get entryModule(): Module; hasEntryModule(): boolean; addModule(module: Module): boolean; removeModule(module: Module): void; getNumberOfModules(): number; get modulesIterable(): Iterable<Module>; compareTo(otherChunk: Chunk): 0 | 1 | -1; containsModule(module: Module): boolean; getModules(): Module[]; remove(): void; moveModule(module: Module, otherChunk: Chunk): void; integrate(otherChunk: Chunk): boolean; canBeIntegrated(otherChunk: Chunk): boolean; isEmpty(): boolean; modulesSize(): number; size(options?: ChunkSizeOptions): number; integratedSize(otherChunk: Chunk, options: ChunkSizeOptions): number; getChunkModuleMaps(filterFn: (m: Module) => boolean): ChunkModuleMaps; hasModuleInGraph( filterFn: (m: Module) => boolean, filterChunkFn?: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): boolean; getChunkMaps(realHash: boolean): ChunkMaps; hasRuntime(): boolean; canBeInitial(): boolean; isOnlyInitial(): boolean; getEntryOptions(): undefined | EntryOptions; addGroup(chunkGroup: ChunkGroup): void; removeGroup(chunkGroup: ChunkGroup): void; isInGroup(chunkGroup: ChunkGroup): boolean; getNumberOfGroups(): number; get groupsIterable(): Iterable<ChunkGroup>; disconnectFromGroups(): void; split(newChunk: Chunk): void; updateHash(hash: Hash, chunkGraph: ChunkGraph): void; getAllAsyncChunks(): Set<Chunk>; getAllInitialChunks(): Set<Chunk>; getAllReferencedChunks(): Set<Chunk>; getAllReferencedAsyncEntrypoints(): Set<Entrypoint>; hasAsyncChunks(): boolean; getChildIdsByOrders( chunkGraph: ChunkGraph, filterFn?: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): Record<string, (string | number)[]>; getChildrenOfTypeInOrder( chunkGraph: ChunkGraph, type: string ): { onChunks: Chunk[]; chunks: Set<Chunk> }[]; getChildIdsByOrdersMap( chunkGraph: ChunkGraph, includeDirectChildren?: boolean, filterFn?: (c: Chunk, chunkGraph: ChunkGraph) => boolean ): Record<string | number, Record<string, (string | number)[]>>; }
3,481
updateCacheModule(module: Module): void
interface Module { hot: webpack.Hot; }
3,482
updateCacheModule(module: Module): void
class Module extends DependenciesBlock { constructor(type: string, context?: string, layer?: string); type: string; context: null | string; layer: null | string; needId: boolean; debugId: number; resolveOptions: ResolveOptionsWebpackOptions; factoryMeta?: object; useSourceMap: boolean; useSimpleSourceMap: boolean; buildMeta: BuildMeta; buildInfo: Record<string, any>; presentationalDependencies?: Dependency[]; codeGenerationDependencies?: Dependency[]; id: string | number; get hash(): string; get renderedHash(): string; profile: null | ModuleProfile; index: number; index2: number; depth: number; issuer: null | Module; get usedExports(): null | boolean | SortableSet<string>; get optimizationBailout(): ( | string | ((requestShortener: RequestShortener) => string) )[]; get optional(): boolean; addChunk(chunk?: any): boolean; removeChunk(chunk?: any): void; isInChunk(chunk?: any): boolean; isEntryModule(): boolean; getChunks(): Chunk[]; getNumberOfChunks(): number; get chunksIterable(): Iterable<Chunk>; isProvided(exportName: string): null | boolean; get exportsArgument(): string; get moduleArgument(): string; getExportsType( moduleGraph: ModuleGraph, strict: boolean ): "namespace" | "default-only" | "default-with-named" | "dynamic"; addPresentationalDependency(presentationalDependency: Dependency): void; addCodeGenerationDependency(codeGenerationDependency: Dependency): void; addWarning(warning: WebpackError): void; getWarnings(): undefined | Iterable<WebpackError>; getNumberOfWarnings(): number; addError(error: WebpackError): void; getErrors(): undefined | Iterable<WebpackError>; getNumberOfErrors(): number; /** * removes all warnings and errors */ clearWarningsAndErrors(): void; isOptional(moduleGraph: ModuleGraph): boolean; isAccessibleInChunk( chunkGraph: ChunkGraph, chunk: Chunk, ignoreChunk?: Chunk ): boolean; isAccessibleInChunkGroup( chunkGraph: ChunkGraph, chunkGroup: ChunkGroup, ignoreChunk?: Chunk ): boolean; hasReasonForChunk( chunk: Chunk, moduleGraph: ModuleGraph, chunkGraph: ChunkGraph ): boolean; hasReasons(moduleGraph: ModuleGraph, runtime: RuntimeSpec): boolean; needBuild( context: NeedBuildContext, callback: (arg0?: null | WebpackError, arg1?: boolean) => void ): void; needRebuild( fileTimestamps: Map<string, null | number>, contextTimestamps: Map<string, null | number> ): boolean; invalidateBuild(): void; identifier(): string; readableIdentifier(requestShortener: RequestShortener): string; build( options: WebpackOptionsNormalized, compilation: Compilation, resolver: ResolverWithOptions, fs: InputFileSystem, callback: (arg0?: WebpackError) => void ): void; getSourceTypes(): Set<string>; source( dependencyTemplates: DependencyTemplates, runtimeTemplate: RuntimeTemplate, type?: string ): Source; size(type?: string): number; libIdent(options: LibIdentOptions): null | string; nameForCondition(): null | string; getConcatenationBailoutReason( context: ConcatenationBailoutReasonContext ): undefined | string; getSideEffectsConnectionState(moduleGraph: ModuleGraph): ConnectionState; codeGeneration(context: CodeGenerationContext): CodeGenerationResult; chunkCondition(chunk: Chunk, compilation: Compilation): boolean; hasChunkCondition(): boolean; /** * Assuming this module is in the cache. Update the (cached) module with * the fresh module from the factory. Usually updates internal references * and properties. */ updateCacheModule(module: Module): void; /** * Module should be unsafe cached. Get data that's needed for that. * This data will be passed to restoreFromUnsafeCache later. */ getUnsafeCacheData(): object; /** * Assuming this module is in the cache. Remove internal references to allow freeing some memory. */ cleanupForCache(): void; originalSource(): null | Source; addCacheDependencies( fileDependencies: LazySet<string>, contextDependencies: LazySet<string>, missingDependencies: LazySet<string>, buildDependencies: LazySet<string> ): void; get hasEqualsChunks(): any; get isUsed(): any; get errors(): any; get warnings(): any; used: any; }
3,483
create( data: ModuleFactoryCreateData, callback: (arg0?: Error, arg1?: ModuleFactoryResult) => void ): void
interface ModuleFactoryResult { /** * the created module or unset if no module was created */ module?: Module; fileDependencies?: Set<string>; contextDependencies?: Set<string>; missingDependencies?: Set<string>; /** * allow to use the unsafe cache */ cacheable?: boolean; }
3,484
create( data: ModuleFactoryCreateData, callback: (arg0?: Error, arg1?: ModuleFactoryResult) => void ): void
interface ModuleFactoryCreateData { contextInfo: ModuleFactoryCreateDataContextInfo; resolveOptions?: ResolveOptionsWebpackOptions; context: string; dependencies: Dependency[]; }
3,485
(arg0?: Error, arg1?: ModuleFactoryResult) => void
interface ModuleFactoryResult { /** * the created module or unset if no module was created */ module?: Module; fileDependencies?: Set<string>; contextDependencies?: Set<string>; missingDependencies?: Set<string>; /** * allow to use the unsafe cache */ cacheable?: boolean; }
3,486
constructor(options: ModuleFederationPluginOptions)
interface ModuleFederationPluginOptions { /** * Modules that should be exposed by this container. When provided, property name is used as public name, otherwise public name is automatically inferred from request. */ exposes?: (string | ExposesObject)[] | ExposesObject; /** * The filename of the container as relative path inside the `output.path` directory. */ filename?: string; /** * Options for library. */ library?: LibraryOptions; /** * The name of the container. */ name?: string; /** * The external type of the remote containers. */ remoteType?: | "import" | "var" | "module" | "assign" | "this" | "window" | "self" | "global" | "commonjs" | "commonjs2" | "commonjs-module" | "commonjs-static" | "amd" | "amd-require" | "umd" | "umd2" | "jsonp" | "system" | "promise" | "script" | "node-commonjs"; /** * Container locations and request scopes from which modules should be resolved and loaded at runtime. When provided, property name is used as request scope, otherwise request scope is automatically inferred from container location. */ remotes?: (string | RemotesObject)[] | RemotesObject; /** * The name of the runtime chunk. If set a runtime chunk with this name is created or an existing entrypoint is used as runtime. */ runtime?: string | false; /** * Share scope name used for all shared modules (defaults to 'default'). */ shareScope?: string; /** * Modules that should be shared in the share scope. When provided, property names are used to match requested modules in this compilation. */ shared?: (string | SharedObject)[] | SharedObject; }
3,487
constructor(options: ModuleFederationPluginOptions)
interface ModuleFederationPluginOptions { /** * Modules that should be exposed by this container. When provided, property name is used as public name, otherwise public name is automatically inferred from request. */ exposes?: Exposes; /** * The filename of the container as relative path inside the `output.path` directory. */ filename?: string; /** * Options for library. */ library?: LibraryOptions; /** * The name of the container. */ name?: string; /** * The external type of the remote containers. */ remoteType?: ExternalsType; /** * Container locations and request scopes from which modules should be resolved and loaded at runtime. When provided, property name is used as request scope, otherwise request scope is automatically inferred from container location. */ remotes?: Remotes; /** * The name of the runtime chunk. If set a runtime chunk with this name is created or an existing entrypoint is used as runtime. */ runtime?: EntryRuntime; /** * Share scope name used for all shared modules (defaults to 'default'). */ shareScope?: string; /** * Modules that should be shared in the share scope. When provided, property names are used to match requested modules in this compilation. */ shared?: Shared; }
3,488
setParents( dependency: Dependency, block: DependenciesBlock, module: Module, indexInBlock?: number ): void
class Dependency { constructor(); weak: boolean; optional: boolean; get type(): string; get category(): string; loc: DependencyLocation; setLoc( startLine?: any, startColumn?: any, endLine?: any, endColumn?: any ): void; getContext(): undefined | string; getResourceIdentifier(): null | string; couldAffectReferencingModule(): boolean | typeof TRANSITIVE; /** * Returns the referenced module and export */ getReference(moduleGraph: ModuleGraph): never; /** * Returns list of exports referenced by this dependency */ getReferencedExports( moduleGraph: ModuleGraph, runtime: RuntimeSpec ): (string[] | ReferencedExport)[]; getCondition( moduleGraph: ModuleGraph ): | null | false | ((arg0: ModuleGraphConnection, arg1: RuntimeSpec) => ConnectionState); /** * Returns the exported names */ getExports(moduleGraph: ModuleGraph): undefined | ExportsSpec; /** * Returns warnings */ getWarnings(moduleGraph: ModuleGraph): WebpackError[]; /** * Returns errors */ getErrors(moduleGraph: ModuleGraph): WebpackError[]; /** * Update the hash */ updateHash(hash: Hash, context: UpdateHashContextDependency): void; /** * implement this method to allow the occurrence order plugin to count correctly */ getNumberOfIdOccurrences(): number; getModuleEvaluationSideEffectsState( moduleGraph: ModuleGraph ): ConnectionState; createIgnoredModule(context: string): Module; serialize(__0: { write: any }): void; deserialize(__0: { read: any }): void; module: any; get disconnect(): any; static NO_EXPORTS_REFERENCED: string[][]; static EXPORTS_OBJECT_REFERENCED: string[][]; static TRANSITIVE: typeof TRANSITIVE; }
3,489
setParents( dependency: Dependency, block: DependenciesBlock, module: Module, indexInBlock?: number ): void
interface Module { hot: webpack.Hot; }
3,490
setParents( dependency: Dependency, block: DependenciesBlock, module: Module, indexInBlock?: number ): void
class Module extends DependenciesBlock { constructor(type: string, context?: string, layer?: string); type: string; context: null | string; layer: null | string; needId: boolean; debugId: number; resolveOptions: ResolveOptionsWebpackOptions; factoryMeta?: object; useSourceMap: boolean; useSimpleSourceMap: boolean; buildMeta: BuildMeta; buildInfo: Record<string, any>; presentationalDependencies?: Dependency[]; codeGenerationDependencies?: Dependency[]; id: string | number; get hash(): string; get renderedHash(): string; profile: null | ModuleProfile; index: number; index2: number; depth: number; issuer: null | Module; get usedExports(): null | boolean | SortableSet<string>; get optimizationBailout(): ( | string | ((requestShortener: RequestShortener) => string) )[]; get optional(): boolean; addChunk(chunk?: any): boolean; removeChunk(chunk?: any): void; isInChunk(chunk?: any): boolean; isEntryModule(): boolean; getChunks(): Chunk[]; getNumberOfChunks(): number; get chunksIterable(): Iterable<Chunk>; isProvided(exportName: string): null | boolean; get exportsArgument(): string; get moduleArgument(): string; getExportsType( moduleGraph: ModuleGraph, strict: boolean ): "namespace" | "default-only" | "default-with-named" | "dynamic"; addPresentationalDependency(presentationalDependency: Dependency): void; addCodeGenerationDependency(codeGenerationDependency: Dependency): void; addWarning(warning: WebpackError): void; getWarnings(): undefined | Iterable<WebpackError>; getNumberOfWarnings(): number; addError(error: WebpackError): void; getErrors(): undefined | Iterable<WebpackError>; getNumberOfErrors(): number; /** * removes all warnings and errors */ clearWarningsAndErrors(): void; isOptional(moduleGraph: ModuleGraph): boolean; isAccessibleInChunk( chunkGraph: ChunkGraph, chunk: Chunk, ignoreChunk?: Chunk ): boolean; isAccessibleInChunkGroup( chunkGraph: ChunkGraph, chunkGroup: ChunkGroup, ignoreChunk?: Chunk ): boolean; hasReasonForChunk( chunk: Chunk, moduleGraph: ModuleGraph, chunkGraph: ChunkGraph ): boolean; hasReasons(moduleGraph: ModuleGraph, runtime: RuntimeSpec): boolean; needBuild( context: NeedBuildContext, callback: (arg0?: null | WebpackError, arg1?: boolean) => void ): void; needRebuild( fileTimestamps: Map<string, null | number>, contextTimestamps: Map<string, null | number> ): boolean; invalidateBuild(): void; identifier(): string; readableIdentifier(requestShortener: RequestShortener): string; build( options: WebpackOptionsNormalized, compilation: Compilation, resolver: ResolverWithOptions, fs: InputFileSystem, callback: (arg0?: WebpackError) => void ): void; getSourceTypes(): Set<string>; source( dependencyTemplates: DependencyTemplates, runtimeTemplate: RuntimeTemplate, type?: string ): Source; size(type?: string): number; libIdent(options: LibIdentOptions): null | string; nameForCondition(): null | string; getConcatenationBailoutReason( context: ConcatenationBailoutReasonContext ): undefined | string; getSideEffectsConnectionState(moduleGraph: ModuleGraph): ConnectionState; codeGeneration(context: CodeGenerationContext): CodeGenerationResult; chunkCondition(chunk: Chunk, compilation: Compilation): boolean; hasChunkCondition(): boolean; /** * Assuming this module is in the cache. Update the (cached) module with * the fresh module from the factory. Usually updates internal references * and properties. */ updateCacheModule(module: Module): void; /** * Module should be unsafe cached. Get data that's needed for that. * This data will be passed to restoreFromUnsafeCache later. */ getUnsafeCacheData(): object; /** * Assuming this module is in the cache. Remove internal references to allow freeing some memory. */ cleanupForCache(): void; originalSource(): null | Source; addCacheDependencies( fileDependencies: LazySet<string>, contextDependencies: LazySet<string>, missingDependencies: LazySet<string>, buildDependencies: LazySet<string> ): void; get hasEqualsChunks(): any; get isUsed(): any; get errors(): any; get warnings(): any; used: any; }
3,491
getParentModule(dependency: Dependency): Module
class Dependency { constructor(); weak: boolean; optional: boolean; get type(): string; get category(): string; loc: DependencyLocation; setLoc( startLine?: any, startColumn?: any, endLine?: any, endColumn?: any ): void; getContext(): undefined | string; getResourceIdentifier(): null | string; couldAffectReferencingModule(): boolean | typeof TRANSITIVE; /** * Returns the referenced module and export */ getReference(moduleGraph: ModuleGraph): never; /** * Returns list of exports referenced by this dependency */ getReferencedExports( moduleGraph: ModuleGraph, runtime: RuntimeSpec ): (string[] | ReferencedExport)[]; getCondition( moduleGraph: ModuleGraph ): | null | false | ((arg0: ModuleGraphConnection, arg1: RuntimeSpec) => ConnectionState); /** * Returns the exported names */ getExports(moduleGraph: ModuleGraph): undefined | ExportsSpec; /** * Returns warnings */ getWarnings(moduleGraph: ModuleGraph): WebpackError[]; /** * Returns errors */ getErrors(moduleGraph: ModuleGraph): WebpackError[]; /** * Update the hash */ updateHash(hash: Hash, context: UpdateHashContextDependency): void; /** * implement this method to allow the occurrence order plugin to count correctly */ getNumberOfIdOccurrences(): number; getModuleEvaluationSideEffectsState( moduleGraph: ModuleGraph ): ConnectionState; createIgnoredModule(context: string): Module; serialize(__0: { write: any }): void; deserialize(__0: { read: any }): void; module: any; get disconnect(): any; static NO_EXPORTS_REFERENCED: string[][]; static EXPORTS_OBJECT_REFERENCED: string[][]; static TRANSITIVE: typeof TRANSITIVE; }
3,492
getParentBlock(dependency: Dependency): DependenciesBlock
class Dependency { constructor(); weak: boolean; optional: boolean; get type(): string; get category(): string; loc: DependencyLocation; setLoc( startLine?: any, startColumn?: any, endLine?: any, endColumn?: any ): void; getContext(): undefined | string; getResourceIdentifier(): null | string; couldAffectReferencingModule(): boolean | typeof TRANSITIVE; /** * Returns the referenced module and export */ getReference(moduleGraph: ModuleGraph): never; /** * Returns list of exports referenced by this dependency */ getReferencedExports( moduleGraph: ModuleGraph, runtime: RuntimeSpec ): (string[] | ReferencedExport)[]; getCondition( moduleGraph: ModuleGraph ): | null | false | ((arg0: ModuleGraphConnection, arg1: RuntimeSpec) => ConnectionState); /** * Returns the exported names */ getExports(moduleGraph: ModuleGraph): undefined | ExportsSpec; /** * Returns warnings */ getWarnings(moduleGraph: ModuleGraph): WebpackError[]; /** * Returns errors */ getErrors(moduleGraph: ModuleGraph): WebpackError[]; /** * Update the hash */ updateHash(hash: Hash, context: UpdateHashContextDependency): void; /** * implement this method to allow the occurrence order plugin to count correctly */ getNumberOfIdOccurrences(): number; getModuleEvaluationSideEffectsState( moduleGraph: ModuleGraph ): ConnectionState; createIgnoredModule(context: string): Module; serialize(__0: { write: any }): void; deserialize(__0: { read: any }): void; module: any; get disconnect(): any; static NO_EXPORTS_REFERENCED: string[][]; static EXPORTS_OBJECT_REFERENCED: string[][]; static TRANSITIVE: typeof TRANSITIVE; }
3,493
getParentBlockIndex(dependency: Dependency): number
class Dependency { constructor(); weak: boolean; optional: boolean; get type(): string; get category(): string; loc: DependencyLocation; setLoc( startLine?: any, startColumn?: any, endLine?: any, endColumn?: any ): void; getContext(): undefined | string; getResourceIdentifier(): null | string; couldAffectReferencingModule(): boolean | typeof TRANSITIVE; /** * Returns the referenced module and export */ getReference(moduleGraph: ModuleGraph): never; /** * Returns list of exports referenced by this dependency */ getReferencedExports( moduleGraph: ModuleGraph, runtime: RuntimeSpec ): (string[] | ReferencedExport)[]; getCondition( moduleGraph: ModuleGraph ): | null | false | ((arg0: ModuleGraphConnection, arg1: RuntimeSpec) => ConnectionState); /** * Returns the exported names */ getExports(moduleGraph: ModuleGraph): undefined | ExportsSpec; /** * Returns warnings */ getWarnings(moduleGraph: ModuleGraph): WebpackError[]; /** * Returns errors */ getErrors(moduleGraph: ModuleGraph): WebpackError[]; /** * Update the hash */ updateHash(hash: Hash, context: UpdateHashContextDependency): void; /** * implement this method to allow the occurrence order plugin to count correctly */ getNumberOfIdOccurrences(): number; getModuleEvaluationSideEffectsState( moduleGraph: ModuleGraph ): ConnectionState; createIgnoredModule(context: string): Module; serialize(__0: { write: any }): void; deserialize(__0: { read: any }): void; module: any; get disconnect(): any; static NO_EXPORTS_REFERENCED: string[][]; static EXPORTS_OBJECT_REFERENCED: string[][]; static TRANSITIVE: typeof TRANSITIVE; }
3,494
setResolvedModule( originModule: Module, dependency: Dependency, module: Module ): void
class Dependency { constructor(); weak: boolean; optional: boolean; get type(): string; get category(): string; loc: DependencyLocation; setLoc( startLine?: any, startColumn?: any, endLine?: any, endColumn?: any ): void; getContext(): undefined | string; getResourceIdentifier(): null | string; couldAffectReferencingModule(): boolean | typeof TRANSITIVE; /** * Returns the referenced module and export */ getReference(moduleGraph: ModuleGraph): never; /** * Returns list of exports referenced by this dependency */ getReferencedExports( moduleGraph: ModuleGraph, runtime: RuntimeSpec ): (string[] | ReferencedExport)[]; getCondition( moduleGraph: ModuleGraph ): | null | false | ((arg0: ModuleGraphConnection, arg1: RuntimeSpec) => ConnectionState); /** * Returns the exported names */ getExports(moduleGraph: ModuleGraph): undefined | ExportsSpec; /** * Returns warnings */ getWarnings(moduleGraph: ModuleGraph): WebpackError[]; /** * Returns errors */ getErrors(moduleGraph: ModuleGraph): WebpackError[]; /** * Update the hash */ updateHash(hash: Hash, context: UpdateHashContextDependency): void; /** * implement this method to allow the occurrence order plugin to count correctly */ getNumberOfIdOccurrences(): number; getModuleEvaluationSideEffectsState( moduleGraph: ModuleGraph ): ConnectionState; createIgnoredModule(context: string): Module; serialize(__0: { write: any }): void; deserialize(__0: { read: any }): void; module: any; get disconnect(): any; static NO_EXPORTS_REFERENCED: string[][]; static EXPORTS_OBJECT_REFERENCED: string[][]; static TRANSITIVE: typeof TRANSITIVE; }
3,495
setResolvedModule( originModule: Module, dependency: Dependency, module: Module ): void
interface Module { hot: webpack.Hot; }
3,496
setResolvedModule( originModule: Module, dependency: Dependency, module: Module ): void
class Module extends DependenciesBlock { constructor(type: string, context?: string, layer?: string); type: string; context: null | string; layer: null | string; needId: boolean; debugId: number; resolveOptions: ResolveOptionsWebpackOptions; factoryMeta?: object; useSourceMap: boolean; useSimpleSourceMap: boolean; buildMeta: BuildMeta; buildInfo: Record<string, any>; presentationalDependencies?: Dependency[]; codeGenerationDependencies?: Dependency[]; id: string | number; get hash(): string; get renderedHash(): string; profile: null | ModuleProfile; index: number; index2: number; depth: number; issuer: null | Module; get usedExports(): null | boolean | SortableSet<string>; get optimizationBailout(): ( | string | ((requestShortener: RequestShortener) => string) )[]; get optional(): boolean; addChunk(chunk?: any): boolean; removeChunk(chunk?: any): void; isInChunk(chunk?: any): boolean; isEntryModule(): boolean; getChunks(): Chunk[]; getNumberOfChunks(): number; get chunksIterable(): Iterable<Chunk>; isProvided(exportName: string): null | boolean; get exportsArgument(): string; get moduleArgument(): string; getExportsType( moduleGraph: ModuleGraph, strict: boolean ): "namespace" | "default-only" | "default-with-named" | "dynamic"; addPresentationalDependency(presentationalDependency: Dependency): void; addCodeGenerationDependency(codeGenerationDependency: Dependency): void; addWarning(warning: WebpackError): void; getWarnings(): undefined | Iterable<WebpackError>; getNumberOfWarnings(): number; addError(error: WebpackError): void; getErrors(): undefined | Iterable<WebpackError>; getNumberOfErrors(): number; /** * removes all warnings and errors */ clearWarningsAndErrors(): void; isOptional(moduleGraph: ModuleGraph): boolean; isAccessibleInChunk( chunkGraph: ChunkGraph, chunk: Chunk, ignoreChunk?: Chunk ): boolean; isAccessibleInChunkGroup( chunkGraph: ChunkGraph, chunkGroup: ChunkGroup, ignoreChunk?: Chunk ): boolean; hasReasonForChunk( chunk: Chunk, moduleGraph: ModuleGraph, chunkGraph: ChunkGraph ): boolean; hasReasons(moduleGraph: ModuleGraph, runtime: RuntimeSpec): boolean; needBuild( context: NeedBuildContext, callback: (arg0?: null | WebpackError, arg1?: boolean) => void ): void; needRebuild( fileTimestamps: Map<string, null | number>, contextTimestamps: Map<string, null | number> ): boolean; invalidateBuild(): void; identifier(): string; readableIdentifier(requestShortener: RequestShortener): string; build( options: WebpackOptionsNormalized, compilation: Compilation, resolver: ResolverWithOptions, fs: InputFileSystem, callback: (arg0?: WebpackError) => void ): void; getSourceTypes(): Set<string>; source( dependencyTemplates: DependencyTemplates, runtimeTemplate: RuntimeTemplate, type?: string ): Source; size(type?: string): number; libIdent(options: LibIdentOptions): null | string; nameForCondition(): null | string; getConcatenationBailoutReason( context: ConcatenationBailoutReasonContext ): undefined | string; getSideEffectsConnectionState(moduleGraph: ModuleGraph): ConnectionState; codeGeneration(context: CodeGenerationContext): CodeGenerationResult; chunkCondition(chunk: Chunk, compilation: Compilation): boolean; hasChunkCondition(): boolean; /** * Assuming this module is in the cache. Update the (cached) module with * the fresh module from the factory. Usually updates internal references * and properties. */ updateCacheModule(module: Module): void; /** * Module should be unsafe cached. Get data that's needed for that. * This data will be passed to restoreFromUnsafeCache later. */ getUnsafeCacheData(): object; /** * Assuming this module is in the cache. Remove internal references to allow freeing some memory. */ cleanupForCache(): void; originalSource(): null | Source; addCacheDependencies( fileDependencies: LazySet<string>, contextDependencies: LazySet<string>, missingDependencies: LazySet<string>, buildDependencies: LazySet<string> ): void; get hasEqualsChunks(): any; get isUsed(): any; get errors(): any; get warnings(): any; used: any; }
3,497
updateModule(dependency: Dependency, module: Module): void
class Dependency { constructor(); weak: boolean; optional: boolean; get type(): string; get category(): string; loc: DependencyLocation; setLoc( startLine?: any, startColumn?: any, endLine?: any, endColumn?: any ): void; getContext(): undefined | string; getResourceIdentifier(): null | string; couldAffectReferencingModule(): boolean | typeof TRANSITIVE; /** * Returns the referenced module and export */ getReference(moduleGraph: ModuleGraph): never; /** * Returns list of exports referenced by this dependency */ getReferencedExports( moduleGraph: ModuleGraph, runtime: RuntimeSpec ): (string[] | ReferencedExport)[]; getCondition( moduleGraph: ModuleGraph ): | null | false | ((arg0: ModuleGraphConnection, arg1: RuntimeSpec) => ConnectionState); /** * Returns the exported names */ getExports(moduleGraph: ModuleGraph): undefined | ExportsSpec; /** * Returns warnings */ getWarnings(moduleGraph: ModuleGraph): WebpackError[]; /** * Returns errors */ getErrors(moduleGraph: ModuleGraph): WebpackError[]; /** * Update the hash */ updateHash(hash: Hash, context: UpdateHashContextDependency): void; /** * implement this method to allow the occurrence order plugin to count correctly */ getNumberOfIdOccurrences(): number; getModuleEvaluationSideEffectsState( moduleGraph: ModuleGraph ): ConnectionState; createIgnoredModule(context: string): Module; serialize(__0: { write: any }): void; deserialize(__0: { read: any }): void; module: any; get disconnect(): any; static NO_EXPORTS_REFERENCED: string[][]; static EXPORTS_OBJECT_REFERENCED: string[][]; static TRANSITIVE: typeof TRANSITIVE; }
3,498
updateModule(dependency: Dependency, module: Module): void
interface Module { hot: webpack.Hot; }
3,499
updateModule(dependency: Dependency, module: Module): void
class Module extends DependenciesBlock { constructor(type: string, context?: string, layer?: string); type: string; context: null | string; layer: null | string; needId: boolean; debugId: number; resolveOptions: ResolveOptionsWebpackOptions; factoryMeta?: object; useSourceMap: boolean; useSimpleSourceMap: boolean; buildMeta: BuildMeta; buildInfo: Record<string, any>; presentationalDependencies?: Dependency[]; codeGenerationDependencies?: Dependency[]; id: string | number; get hash(): string; get renderedHash(): string; profile: null | ModuleProfile; index: number; index2: number; depth: number; issuer: null | Module; get usedExports(): null | boolean | SortableSet<string>; get optimizationBailout(): ( | string | ((requestShortener: RequestShortener) => string) )[]; get optional(): boolean; addChunk(chunk?: any): boolean; removeChunk(chunk?: any): void; isInChunk(chunk?: any): boolean; isEntryModule(): boolean; getChunks(): Chunk[]; getNumberOfChunks(): number; get chunksIterable(): Iterable<Chunk>; isProvided(exportName: string): null | boolean; get exportsArgument(): string; get moduleArgument(): string; getExportsType( moduleGraph: ModuleGraph, strict: boolean ): "namespace" | "default-only" | "default-with-named" | "dynamic"; addPresentationalDependency(presentationalDependency: Dependency): void; addCodeGenerationDependency(codeGenerationDependency: Dependency): void; addWarning(warning: WebpackError): void; getWarnings(): undefined | Iterable<WebpackError>; getNumberOfWarnings(): number; addError(error: WebpackError): void; getErrors(): undefined | Iterable<WebpackError>; getNumberOfErrors(): number; /** * removes all warnings and errors */ clearWarningsAndErrors(): void; isOptional(moduleGraph: ModuleGraph): boolean; isAccessibleInChunk( chunkGraph: ChunkGraph, chunk: Chunk, ignoreChunk?: Chunk ): boolean; isAccessibleInChunkGroup( chunkGraph: ChunkGraph, chunkGroup: ChunkGroup, ignoreChunk?: Chunk ): boolean; hasReasonForChunk( chunk: Chunk, moduleGraph: ModuleGraph, chunkGraph: ChunkGraph ): boolean; hasReasons(moduleGraph: ModuleGraph, runtime: RuntimeSpec): boolean; needBuild( context: NeedBuildContext, callback: (arg0?: null | WebpackError, arg1?: boolean) => void ): void; needRebuild( fileTimestamps: Map<string, null | number>, contextTimestamps: Map<string, null | number> ): boolean; invalidateBuild(): void; identifier(): string; readableIdentifier(requestShortener: RequestShortener): string; build( options: WebpackOptionsNormalized, compilation: Compilation, resolver: ResolverWithOptions, fs: InputFileSystem, callback: (arg0?: WebpackError) => void ): void; getSourceTypes(): Set<string>; source( dependencyTemplates: DependencyTemplates, runtimeTemplate: RuntimeTemplate, type?: string ): Source; size(type?: string): number; libIdent(options: LibIdentOptions): null | string; nameForCondition(): null | string; getConcatenationBailoutReason( context: ConcatenationBailoutReasonContext ): undefined | string; getSideEffectsConnectionState(moduleGraph: ModuleGraph): ConnectionState; codeGeneration(context: CodeGenerationContext): CodeGenerationResult; chunkCondition(chunk: Chunk, compilation: Compilation): boolean; hasChunkCondition(): boolean; /** * Assuming this module is in the cache. Update the (cached) module with * the fresh module from the factory. Usually updates internal references * and properties. */ updateCacheModule(module: Module): void; /** * Module should be unsafe cached. Get data that's needed for that. * This data will be passed to restoreFromUnsafeCache later. */ getUnsafeCacheData(): object; /** * Assuming this module is in the cache. Remove internal references to allow freeing some memory. */ cleanupForCache(): void; originalSource(): null | Source; addCacheDependencies( fileDependencies: LazySet<string>, contextDependencies: LazySet<string>, missingDependencies: LazySet<string>, buildDependencies: LazySet<string> ): void; get hasEqualsChunks(): any; get isUsed(): any; get errors(): any; get warnings(): any; used: any; }