On this page

Defines the known meta type used by this module.

new ModuleGraph(): ModuleGraph

Defines the known meta type used by this module.

  • ModuleGraphConnection {typeof ModuleGraphConnection}
addExplanation(dependency, explanation): void
Attributes
dependency:<Dependency>
the referencing dependency
explanation:<string>
an explanation
Returns:<void>

Adds the provided dependency to the module graph.


addExtraReason(module, explanation): void
Attributes
module:<Module>
the referenced module
explanation:<string>
an explanation why it's referenced
Returns:<void>

Adds the provided module to the module graph.


cached(fn, ...args?): R
Attributes
computer
args:
{T} arguments
Returns:
{R} computed value or cached

Returns computed value or cached.


cloneModuleAttributes(sourceModule, targetModule): void
Attributes
sourceModule:<Module>
the source module
targetModule:<Module>
the target module
Returns:<void>

Clones module attributes.


copyOutgoingModuleConnections(oldModule, newModule, filterConnection): void
Attributes
oldModule:<Module>
the old referencing module
newModule:<Module>
the new referencing module
filterConnection:<Function>
filter predicate for replacement
Returns:<void>

Copies outgoing module connections.


dependencyCacheProvide(dependency, ...args?): void
  • dependency {D} dependency
  • args <Tuple><<ARGS>, <unknown>> arguments, last argument is a function called with moduleGraph, dependency, ...args
  • Returns: {R} computed value or cached

Dependency cache provide.


finishUpdateParent(): void
Returns:<void>

Finish update parent.


freeze(cacheStage?): void
Attributes
cacheStage:<string>
a persistent stage name for caching
Returns:<void>

Processes the provided cache stage.


getConnection(dependency): ModuleGraphConnection | undefined
Attributes
dependency:<Dependency>
the dependency to look for a referenced module
the connection

Returns the connection.


getDepth(module): number | null
Attributes
module:<Module>
the module
Returns:<number> | <null>
the depth of the module

Returns the depth of the module.


getExportInfo(module, exportName): ExportInfo
Attributes
module:<Module>
the module
exportName:<string>
the export
Returns:<ExportInfo>
info about the export

Returns info about the export.


getExportsInfo(module): ExportsInfo
Attributes
module:<Module>
the module
info about the exports

Returns info about the exports.


getIncomingConnections(module): Iterable
Attributes
module:<Module>
the module
Returns:<Iterable>
< <ModuleGraphConnection> > reasons why a module is included

Gets incoming connections.


getIncomingConnectionsByOriginModule(module): ReadonlyMap
Attributes
module:<Module>
the module
Returns:
<ReadonlyMap> < <Module> | <null> | <undefined> , <readonly ModuleGraphConnection[]> > reasons why a module is included, in a map by source module

Gets incoming connections by origin module.


getIssuer(module): Issuer
Attributes
module:<Module>
the module
Returns:<Issuer>
the issuer module

Returns the issuer module.


getMeta(thing): Meta
Attributes
thing:<object>
any thing
Returns:<Meta>
metadata

Returns metadata.


getMetaIfExisting(thing): Meta | undefined
Attributes
thing:<object>
any thing
metadata

Gets meta if existing.


getModule(dependency): Module | null
Attributes
dependency:<Dependency>
the dependency to look for a referenced module
Returns:<Module> | <null>
the referenced module

Returns the referenced module.


getOptimizationBailout(module): string | Function
Attributes
module:<Module>
the module
[] optimization bailouts

Gets optimization bailout.


getOrigin(dependency): Module | null
Attributes
dependency:<Dependency>
the dependency to look for a referencing module
Returns:<Module> | <null>
the referencing module

Returns the referencing module.


getOutgoingConnections(module): Iterable
Attributes
module:<Module>
the module
Returns:<Iterable>
< <ModuleGraphConnection> > list of outgoing connections

Gets outgoing connections.


getOutgoingConnectionsByModule(module): ReadonlyMap
Attributes
module:<Module>
the module
Returns:
<ReadonlyMap> < <Module> | <undefined> , <readonly ModuleGraphConnection[]> > | <undefined> connections to modules, in a map by module

Gets outgoing connections by module.


getParentBlock(dependency): DependenciesBlock | undefined
Attributes
dependency:<Dependency>
the dependency
parent block

Returns parent block.


getParentBlockIndex(dependency): number
Attributes
dependency:<Dependency>
the dependency
Returns:<number>
index

Gets parent block index.


getParentModule(dependency): Module | undefined
Attributes
dependency:<Dependency>
the dependency
parent module

Gets parent module.


getPostOrderIndex(module): number | null
Attributes
module:<Module>
the module
Returns:<number> | <null>
the index of the module

Gets post order index.


getPreOrderIndex(module): number | null
Attributes
module:<Module>
the module
Returns:<number> | <null>
the index of the module

Gets pre order index.


getProfile(module): ModuleProfile | undefined
Attributes
module:<Module>
the module
the module profile

Returns the module profile.


getProvidedExports(module): true | string
Attributes
module:<Module>
the module
Returns:
<true> | <string> [] | <null> the provided exports

Gets provided exports.


getReadOnlyExportInfo(module, exportName): ExportInfo
Attributes
module:<Module>
the module
exportName:<string>
the export
Returns:<ExportInfo>
info about the export (do not modify)

Gets read only export info.


getResolvedModule(dependency): Module | null
Attributes
dependency:<Dependency>
the dependency to look for a referenced module
Returns:<Module> | <null>
the referenced module

Gets resolved module.


getResolvedOrigin(dependency): Module | null
Attributes
dependency:<Dependency>
the dependency to look for a referencing module
Returns:<Module> | <null>
the original referencing module

Gets resolved origin.


getUsedExports(module, runtime): boolean | SortableSet
Attributes
module:<Module>
the module
the runtime
< <string> > | <null> the used exports false: module is not used at all. true: the module namespace/object export is used. SortableSet : these export names are used. empty SortableSet : module is used but no export. null: unknown, worst case should be assumed.

Returns the used exports.


isAsync(module): boolean
Attributes
module:<Module>
the module
Returns:<boolean>
true, if the module is async

Checks whether this module graph is async.


isDeferred(module): boolean
Attributes
module:<Module>
the module
Returns:<boolean>
true, if the module is used as a deferred module at least once

Checks whether this module graph is deferred.


isExportProvided(module, exportName): boolean | null
Attributes
module:<Module>
the module
exportName:<string> | <string>
[] a name of an export
Returns:<boolean> | <null>
true, if the export is provided by the module. null, if it's unknown. false, if it's not provided.

Checks whether this module graph is export provided.


moveModuleConnections(oldModule, newModule, filterConnection): void
Attributes
oldModule:<Module>
the old referencing module
newModule:<Module>
the new referencing module
filterConnection:<Function>
filter predicate for replacement
Returns:<void>

Move module connections.


removeAllModuleAttributes(): void
Returns:<void>

Removes all module attributes.


removeConnection(dependency): void
Attributes
dependency:<Dependency>
the referencing dependency
Returns:<void>

Removes connection.


removeModuleAttributes(module): void
Attributes
module:<Module>
the module
Returns:<void>

Removes module attributes.


setAsync(module): void
Attributes
module:<Module>
the module
Returns:<void>

Updates async using the provided module.


setDepth(module, depth): void
Attributes
module:<Module>
the module
depth:<number>
the depth of the module
Returns:<void>

Updates depth using the provided module.


setDepthIfLower(module, depth): boolean
Attributes
module:<Module>
the module
depth:<number>
the depth of the module
Returns:<boolean>
true, if the depth was set

Sets depth if lower.


setIssuer(module, issuer): void
Attributes
module:<Module>
the module
issuer:<Module> | <null>
the issuer module
Returns:<void>

Updates issuer using the provided module.


setIssuerIfUnset(module, issuer): void
Attributes
module:<Module>
the module
issuer:<Module> | <null>
the issuer module
Returns:<void>

Sets issuer if unset.


setModuleMemCaches(moduleMemCaches): void
Attributes
moduleMemCaches:<Map>
< <Module> , <WeakTupleMap> < <any> [], <any> >> mem caches for modules for better caching
Returns:<void>

Sets module mem caches.


setParentDependenciesBlockIndex(dependency, index): void
Attributes
dependency:<Dependency>
the dependency
index:<number>
the index
Returns:<void>

Sets parent dependencies block index.


setParents(dependency, block, module, indexInBlock?): void
Attributes
dependency:<Dependency>
the dependency
parent block
module:<Module>
parent module
indexInBlock:<number>
position in block
Returns:<void>

Updates parents using the provided dependency.


setPostOrderIndex(module, index): void
Attributes
module:<Module>
the module
index:<number>
the index of the module
Returns:<void>

Sets post order index.


setPostOrderIndexIfUnset(module, index): boolean
Attributes
module:<Module>
the module
index:<number>
the index of the module
Returns:<boolean>
true, if the index was set

Sets post order index if unset.


setPreOrderIndex(module, index): void
Attributes
module:<Module>
the module
index:<number>
the index of the module
Returns:<void>

Sets pre order index.


setPreOrderIndexIfUnset(module, index): boolean
Attributes
module:<Module>
the module
index:<number>
the index of the module
Returns:<boolean>
true, if the index was set

Sets pre order index if unset.


setProfile(module, profile?): void
Attributes
module:<Module>
the module
the module profile
Returns:<void>

Updates profile using the provided module.


setResolvedModule(originModule, dependency, module): void
Attributes
originModule:<Module> | <null>
the referencing module
dependency:<Dependency>
the referencing dependency
module:<Module>
the referenced module
Returns:<void>

Sets resolved module.


unfreeze(): void
Returns:<void>

Defines the known meta type used by this module.


updateModule(dependency, module): void
Attributes
dependency:<Dependency>
the referencing dependency
module:<Module>
the referenced module
Returns:<void>

Updates module using the provided dependency.


updateParent(dependency, connection?, parentModule?): void
Attributes
dependency:<Dependency>
the need update dependency
the target connection
parentModule:<Module>
the parent module
Returns:<void>

Updates parent using the provided dependency.


Attributes
module:<Module>
the module
Returns:<void>

Clear module graph for module.


Attributes
module:<Module>
the module
deprecateMessage:<string>
message for the deprecation message
deprecationCode:<string>
code for the deprecation
the module graph

Gets module graph for module.


Attributes
module:<Module>
the module
moduleGraph:<ModuleGraph>
the module graph
Returns:<void>

Sets module graph for module.


Attributes
deferredImportVarMap:<Map>
importVarMap:<Map>

& <Record> < <symbol> , <string> []> & <Record> < <string> , <any> >