MCPcopy
hub / github.com/webpack/webpack / getMergedModuleRuntime

Function getMergedModuleRuntime

lib/optimize/ModuleConcatenationPlugin.js:42–52  ·  view source on GitHub ↗
(chunkGraph, cache, module)

Source from the content-addressed store, hash-verified

40 * @returns {RuntimeSpec} the merged runtime
41 */
42const getMergedModuleRuntime = (chunkGraph, cache, module) => {
43 const cached = cache.get(module);
44 if (cached !== undefined || cache.has(module)) return cached;
45 /** @type {RuntimeSpec} */
46 let runtime;
47 for (const r of chunkGraph.getModuleRuntimes(module)) {
48 runtime = mergeRuntimeOwned(runtime, r);
49 }
50 cache.set(module, runtime);
51 return runtime;
52};
53
54/**
55 * Defines the statistics type used by this module.

Callers 2

applyMethod · 0.85
_tryToAddMethod · 0.85

Calls 5

mergeRuntimeOwnedFunction · 0.85
getModuleRuntimesMethod · 0.80
getMethod · 0.45
hasMethod · 0.45
setMethod · 0.45

Tested by

no test coverage detected