MCPcopy
hub / github.com/webpack/webpack / getResolveContext

Method getResolveContext

lib/NormalModule.js:1152–1168  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1150 * @returns {ResolveContext} resolve context
1151 */
1152 const getResolveContext = () => ({
1153 fileDependencies: {
1154 add: (d) =>
1155 /** @type {AnyLoaderContext} */
1156 (loaderContext).addDependency(d)
1157 },
1158 contextDependencies: {
1159 add: (d) =>
1160 /** @type {AnyLoaderContext} */
1161 (loaderContext).addContextDependency(d)
1162 },
1163 missingDependencies: {
1164 add: (d) =>
1165 /** @type {AnyLoaderContext} */
1166 (loaderContext).addMissingDependency(d)
1167 }
1168 });
1169 const getAbsolutify = memoize(() =>
1170 absolutify.bindCache(compilation.compiler.root)
1171 );

Callers

nothing calls this directly

Calls 3

addDependencyMethod · 0.65
addContextDependencyMethod · 0.65
addMissingDependencyMethod · 0.65

Tested by

no test coverage detected